Set of shared ESLint-opinionated configurations for the Joinnus organization.
yarn add -D @joinnus-team/eslint-config
Just replace
yarn
withnpm
if you are using it instead.
You need to make sure that peerDependencies
are installed.
If you are using a package manager that does not perform this automatically, you'll have to do it manually:
npm >= 7
peerDependencies
are installed automatically. If you are using it, ignore this step.
yarn add -D @joinnus-team/eslint-config \
eslint \
eslint-config-prettier \
eslint-plugin-import \
eslint-plugin-node \
eslint-plugin-unicorn \
prettier \
prettier-plugin-organize-imports \
prettier-plugin-pkg
In your .eslintrc.json
:
{
"extends": "@joinnus-team/eslint-config/{preset}"
}
Where {preset}
is one of the available presets.
Check out the ESLint documentation other formats to use shared configurations and override some configs.
You also need to use the related prettier configuration.
In your .prettierrc.json
:
"@joinnus-team/eslint-config/default-prettier-config"
The default export from this package offers rules for Node.js 16 and up. Other available presets are:
node-erbium
: For Node.js 12 applications.node-fermium
For Node.js 14 applications.node-gallium
For Node.js 16 applications.
Check out CONTRIBUTING.