User:Yivan000/common.js

Hello, you have come here looking for the meaning of the word User:Yivan000/common.js. In DICTIOUS you will not only get to know all the dictionary meanings for the word User:Yivan000/common.js, but we will also tell you about its etymology, its characteristics and you will know how to say User:Yivan000/common.js in singular and plural. Everything you need to know about the word User:Yivan000/common.js you have here. The definition of the word User:Yivan000/common.js will help you to be more precise and correct when speaking or writing your texts. Knowing the definition ofUser:Yivan000/common.js, as well as those of other words, enriches your vocabulary and provides you with more and better linguistic resources.
// Remove single-letter entries from recent changes

mw.loader.using('mediawiki.util').then(function () {
    var minLength = 2;  // Minimum title length to show

    function filterRecentChanges() {
        document.querySelectorAll('.mw-changeslist li').forEach(function (li) {
            var link = li.querySelector('span.mw-title');
            if (link) {
                var title = link.textContent.trim();
                if (title.length < minLength) {
                    li.style.display = 'none'; // Hide the entry
                }
            }
        });
    }

    // Run filter after the page loads
    $(document).ready(filterRecentChanges);
});