yarn add -D @prunus/eslint-config;
npx install-peerdeps --dev @prunus/eslint-config;
or
yarn add -D @prunus/eslint-config eslint typescript
Add to your eslint config (.eslintrc, or eslintConfig field in package.json):
{
"extends": "@prunus"
}
yarn add -D eslint @prunus/eslint-config eslint-plugin-import-helpers
Add to your eslint config (.eslintrc, or eslintConfig field in package.json):
{
"extends": "@prunus/eslint-config/js"
}
yarn add -D eslint @prunus/eslint-config eslint-plugin-import-helpers eslint-plugin-react eslint-plugin-react-hooks
Add to your eslint config (.eslintrc, or eslintConfig field in package.json):
{
"extends": "@prunus/eslint-config/jsx"
}
yarn add -D eslint @prunus/eslint-config @typescript-eslint/eslint-plugin @typescript-eslint/parser eslint-plugin-import-helpers typescript
Add to your eslint config (.eslintrc, or eslintConfig field in package.json):
{
"extends": "@prunus/eslint-config/ts"
}
It's the same thing as full installation
Follow scripts create:
npm set-script lint "eslint ."
npm set-script lint:fix "eslint . --fix"
Setup with husky using yarn:
npx husky add .husky/pre-push 'yarn lint'
Setup with husky using npm:
npx husky add .husky/pre-push 'npm run lint'