Jump to content

User:Ingenuity/cleaner

From Wikipedia, the free encyclopedia
cleaner.js
DescriptionFix common WP:MOS issues
Author(s)User:Ingenuity
UpdatedFebruary 17, 2023
    (19 months ago)
SourceUser:Ingenuity/cleaner.js

Adds a notice to the bottom-left hand corner of a page which highlights common Wikipedia:Manual of Style problems with articles.

Overview

[edit]

This script is a work in progress; it has several known bugs, so editors should not just use it on every page. This is a list of known problems:

  • Misplaced section headings and Cannot find {{reflist}} template: if there are any templates at the end of the article (such as stub tags), these will move those templates as well/place them in the wrong position.
  • Curly quotes used: while this does work in a vast majority of cases, sometimes curly quotes are preferred over straight quotes (for example, in location data, such as 11°41′50″N 165°16′19″E)

If you find any additional bugs, please feel free to message me on my talk page. New features are added often; I do my best to test them, but I can't find out every problem.

List of functions

[edit]
  • Cannot find {{reflist}} template: if there is no references section in an article, it will be added.
  • Misplaced punctuation or spaces around <ref> tags: if punctuation is placed after references, their positions will be switched. If there are spaces before the ref tags, it will remove those as well. (guideline)
  • Misplaced section headings: Fixes the positions of References, See also, and Further reading sections. (guideline)
  • Links in headings: removes wikilinks from section headings. (guideline)
  • Curly quotes used: replaces curly quotation marks and apostrophes with their straight versions. (guideline)

If you have a suggestion for a new feature, please let me know.