Socket
Socket
Sign inDemoInstall

eslint-plugin-mediawiki

Package Overview
Dependencies
144
Maintainers
4
Versions
14
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

    eslint-plugin-mediawiki

MediaWiki-specific linting rules, for use in MediaWiki core and extensions.


Version published
Weekly downloads
34K
increased by27.78%
Maintainers
4
Created
Weekly downloads
 

Readme

Source

eslint-plugin-mediawiki

MediaWiki-specific linting rules, for use in MediaWiki core and extensions.

Usage

If you are developing in MediaWiki you should be using eslint-config-wikimedia which includes this plugin.

Add mediawiki to the plugins section of your .eslintrc configuration file, then enable the required rules.

{
  "plugins": [
    "mediawiki"
  ],
  "rules": {
    "mediawiki/msg-doc": "error"
  }
}

Rules

  • mediawiki/class-doc - Ensures CSS classes are documented when they are constructed.
  • mediawiki/msg-doc - Ensures message keys are documented when they are constructed.
  • mediawiki/valid-package-file-require- Ensures required files are in the format that is expected within ResourceLoader package modules, i.e. contain the file extension and are proper relative paths, e.g. ./foo.js instead of ./foo or foo.js.
  • mediawiki/no-vue-dynamic-i18n - Ensures that $i18n() and v-i18n-html are not passed dynamic message keys in Vue templates

Development

npm install
npm test

License

Distributed under the MIT license. See LICENSE for details.

Keywords

FAQs

Last updated on 30 Apr 2020

Did you know?

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc