eslint-plugin-rc-leaflet
v1.4.0
Published
eslint plugin of rc-leaflet
Downloads
13
Maintainers
Readme
eslint-plugin-rc-leaflet
eslint-plugin-rc-leaflet
Installation
You'll first need to install ESLint:
$ npm i eslint --save-dev
Next, install eslint-plugin-rc-leaflet
:
$ npm install eslint-plugin-rc-leaflet --save-dev
Note: If you installed ESLint globally (using the -g
flag) then you must also install eslint-plugin-rc-leaflet
globally.
Usage
Add rc-leaflet
to the plugins
section of your .eslintrc
configuration file. You can omit the eslint-plugin-
prefix:
{
"plugins": [
"rc-leaflet"
]
}
Then configure the rules you want to use under the extends
section, there are six rule groups in total:
{
"extends": [
"plugin:rc-leaflet/es-dev"
]
}
{
"extends": [
"plugin:rc-leaflet/es-prod"
]
}
{
"extends": [
"plugin:rc-leaflet/ts-dev"
]
}
{
"extends": [
"plugin:rc-leaflet/ts-prod"
]
}
{
"extends": [
"plugin:rc-leaflet/react-dev"
]
}
{
"extends": [
"plugin:rc-leaflet/react-prod"
]
}
You can also use list of rules together, configs below means your project use Typescript
+ React
in prod
env:
{
"plugins": [
"rc-leaflet"
],
"extends": [
"plugin:rc-leaflet/ts-prod",
"plugin:rc-leaflet/react-prod"
]
}