eslint-plugin-strict-pattern-matching
v0.1.5
Published
prevent using non-exhaustive pattern matching in typescript
Downloads
247
Maintainers
Readme
eslint-plugin-strict-pattern-matching
prevent using non-exhaustive pattern matching in typescript
Installation
You'll first need to install ESLint:
npm i eslint --save-dev
Next, install eslint-plugin-strict-pattern-matching
:
npm eslint-plugin-strict-pattern-matching --save-dev
Usage
Add strict-pattern-matching
to the plugins section of your .eslintrc
configuration file. You can omit the eslint-plugin-
prefix:
{
"plugins": [
"strict-pattern-matching"
]
}
Then configure the rules you want to use under the rules section.
{
"rules": {
"strict-pattern-matching/rule-name": 2
}
}
Rules
TODO: Run eslint-doc-generator to generate the rules list.