eslint-plugin-wc
ESLint plugin for Web Components.
Install
$ npm i -D eslint eslint-plugin-wc
Usage
Add wc
to the plugins section of your .eslintrc
file:
{
"plugins": ["wc"]
}
Configure your rules like so:
{
"rules": {
"wc/rule-name": "error"
}
}
Configuration
You may also extend the recommended configuration like so:
{
"extends": ["plugin:wc/recommended"],
"env": {"browser": true}
}
Or the best practice configuration which extends this to include all
best practice rules:
{
"extends": ["plugin:wc/best-practice"],
"env": {"browser": true}
}
Supported Rules
Possible Errors (recommended)
Best Practice