Installation
Install the package with
npm install eslint-config-sw-in --save-dev
# or
yarn add eslint-config-sw-in -D
eslint-config-sw-in
requires you to take care of it's peerDependencies
.
Install the correct version of each peerDependencies
package, which are listed
with the following command:
npm info "eslint-config-sw-in@latest" peerDependencies
If using npm 5+, use this shortcut:
npx install-peerdeps --dev eslint-config-sw-in
# or
yarn add eslint-config-sw-in -D --peer
Usage
Now add eslint-config-sw-in
to either your package.json
:
{
"eslintConfig": {
"extends": "eslint-config-sw-in"
}
}
to your .eslintrc
:
{
"extends": "eslint-config-sw-in"
}
or .eslintrc.js
:
module.exports = {
extends: 'eslint-config-sw-in'
};
Prettier Config
This is how you can use or extend the eslint-config-sw-in
prettier config in your
app:
// .prettierrc.js
module.exports = {
...require('eslint-config-sw-in/prettier.config')
};