Difference between revisions of "MediaWiki:Common.js"
Jump to navigation
Jump to search
Line 1: | Line 1: | ||
− | + | // Ensure everything loads properly | |
− | ('#free_text').wikiEditor; | + | mw.loader.using(['jquery.ui'], function() { |
+ | $.getScript('//cmp.osano.com/Azyw1RRk4ZCOx2wli/04c9aa84-7b4a-45a8-bb7e-3b3767dd3378/osano.js', function() { | ||
+ | console.log("Osano script loaded."); | ||
+ | |||
+ | // WikiEditor initialization | ||
+ | $(function() { | ||
+ | if ($('#free_text').length) { // Make sure the element exists | ||
+ | $('#free_text').wikiEditor(); | ||
+ | } | ||
+ | }); | ||
+ | }); | ||
+ | }); |
Revision as of 21:10, 28 August 2024
// Ensure everything loads properly
mw.loader.using(['jquery.ui'], function() {
$.getScript('//cmp.osano.com/Azyw1RRk4ZCOx2wli/04c9aa84-7b4a-45a8-bb7e-3b3767dd3378/osano.js', function() {
console.log("Osano script loaded.");
// WikiEditor initialization
$(function() {
if ($('#free_text').length) { // Make sure the element exists
$('#free_text').wikiEditor();
}
});
});
});