eslint-plugin-stencil

0.0.1 • Public • Published

eslint-plugin-stencil

ESLint rules specific to Stencil JS projects created by the Add To Event Team.

Installation

You'll first need to install ESLint:

$ npm i eslint --save-dev

Next, install eslint-plugin-stencil:

$ npm install eslint-plugin-stencil --save-dev

Note: If you installed ESLint globally (using the -g flag) then you must also install `eslint-plugin-stencil** globally.

Note: Assumes you are also using @typescript-eslint.

Usage

Add stencil to the plugins section of your .eslintrc configuration file. You can omit the eslint-plugin- prefix:

{
    "plugins": [
        "stencil"
    ]
}

Then configure the rules you want to use under the rules section.

{
    "rules": {
        "stencil/no-global-html-attribute-prop-names": "error"
    }
}

Or alternatively extend the Stencil recommended ruleset:

{
    "extends": [
        "plugin:stencil/recommended"
    ]
}

Supported Rules

  • no-global-html-attribute-prop-names

This rule catches Stencil Prop names that share names of Global HTML Attributes.

Contributing

When submitting new rules please:

  • Describe your new rule in the README.md
  • Provide a suite of unit tests for your rule
  • Follow ESLint Rule guidelines (the eslint-rule yeoman generator is good for this)

All contributions welcome.

Licence

Package Sidebar

Install

npm i eslint-plugin-stencil

Weekly Downloads

57

Version

0.0.1

License

MIT

Unpacked Size

6.54 kB

Total Files

7

Last publish

Collaborators

  • atedevelopers
  • elmarti
  • tomthu