User:Jon Harald Søby/namescript.js
Jump to navigation
Jump to search
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)
- Edge: Hold Ctrl while clicking Refresh, or press Ctrl-F5.
if (typeof window === 'object' &&
typeof document === 'object' &&
typeof mw === 'object' &&
typeof $ === 'function') {
const sourceUser = 'Jon_Harald_Søby'; // **IF YOU COPY THIS USER SCRIPT TO YOUR OWN PAGE, REPLACE THIS WITH YOUR OWN USER NAME**
$.get('https://www.wikidata.org/w/index.php?title=User:' + sourceUser + '/namescript-browser.js&action=raw&ctype=text/javascript');
} else if (typeof require === 'function') {
require('./namescript-cli.js');
} else {
console.error('Could not detect environment!');
}