MediaWiki:Common.js
From jugglingpatterns
Note: After publishing, you may have to bypass your browser's cache to see the changes.
- Firefox / Safari: Hold Shift while clicking Reload, or press either Ctrl-F5 or Ctrl-R (⌘-R on a Mac)
- Google Chrome: Press Ctrl-Shift-R (⌘-Shift-R on a Mac)
- Internet Explorer / Edge: Hold Ctrl while clicking Refresh, or press Ctrl-F5
- Opera: Press Ctrl-F5.
// 'scripts' => array( '/js/animation-widget-standalone.mjs', 'js/siteswap.mjs' ), // these two scripts loaded in /etc/mediawiki/LocalSettings.php var siteswapnr = "531"; console.log("siteswapnr " + siteswapnr); var sw=new Siteswap(siteswapnr); var myjson = {jugglers:2, limbs:"ABCD"}; console.log(JSON.stringify(sw)); myjson.props=Array.apply(null, Array(sw.nProps)).map(function () {return {}}) var jif=sw.toJif(myjson); console.log(JSON.stringify(jif));