eslint-config-platypus 1.18.0-3
Install from the command line:
Learn more about npm packages
$ npm install @92green/eslint-config-platypus@1.18.0-3
Install via package.json:
"@92green/eslint-config-platypus": "1.18.0-3"
About this version
A reusable linting config for eslint with a focus on code quality and readability.
install
npm i --save-dev eslint-config-platypus
if you do not have typescript
npm i --save-dev typescript
create a eslint config file .eslintrc.js
module.exports = { extends: ["eslint-config-platypus"] }
The default configuration contains rules for
- code quality
- formatting
- jest
- secrets
- typescript
If you wish to use the React configuration, which includes linting rules for react, react hooks as well as jest dom, install these additional dependencies:
npm i eslint-plugin-jest-dom eslint-plugin-react eslint-plugin-react-hooks --save-dev
Next extend the eslint config
module.exports = { extends: [
"eslint-config-platypus",
"eslint-config-platypus/react-addon"
] }
If you wish to use the rxjs addon
npm i eslint-plugin-rxjs --save-dev
module.exports = { extends: [
"eslint-config-platypus",
"eslint-config-platypus/rxjs-addon"
] }