@bensaufley/eslint-config
v1.1.3
Published
ESLint config with Prettier, TypeScript, and Preact in mind
Downloads
19
Maintainers
Readme
@bensaufley/eslint-config
ESLint configuration for JS/TS-based projects, with or without a frontend in Preact.
Installation
Available as an npm package.
npm install --save-dev @bensaufley/eslint-config
Peer dependencies must also be installed:
npm install --save-dev \
eslint \
@typescript-eslint/eslint-plugin \
@typescript-eslint/parser \
eslint-config-airbnb-base \
eslint-config-prettier \
eslint-import-resolver-typescript \
eslint-plugin-import \
eslint-plugin-prefer-arrow-functions \
eslint-plugin-prettier \
eslint-plugin-simple-import-sort \
prettier
If you're using Preact, you'll also need to install the relevant peer dependencies:
npm install --save-dev \
eslint-config-airbnb \
eslint-plugin-jsx-a11y \
eslint-plugin-react \
eslint-plugin-react-hooks
Usage
In .eslintrc
:
module.exports = {
extends: ['@bensaufley']
}
For a Preact environment:
module.exports = {
extends: [require.resolve('@bensaufley/eslint-config/preact.cjs')]
}