User:Marco/common.js: Difference between revisions

From IIFQ
No edit summary
No edit summary
 
Line 1: Line 1:
var numWords = $("#mw-content-text > div").text().split(" ").length;
var conf = mw.config.get([
var headerWords = $("h1").text().split(" ").length;
'wgAllowUserJs'
var totalWords = numWords + headerWords;
]);
var timeInMinutes = totalWords / 200;
var header = $("h1").text();
$("h1").text(header + " (it will take you " + timeInMinutes + " minutes to read this page)");


//window.alert("animatedMap gadget loaded");
window.alert($conf);
//mw.loader.using(['animatedMap']).then(function () {
//};

Latest revision as of 04:45, 10 January 2024

var conf = mw.config.get([
	'wgAllowUserJs'
]);

window.alert($conf);