2.0.3 • Published 10 months ago
@withyoutecnologia/eslint-config v2.0.3
Eslint Config for Café e Design
Whats included?
- React plugin;
- React Hooks plugin;
- JSX a11y plugin;
Setup
- Install the dependencies
pnpm i eslint @withyoutecnologia/eslint-config -D
- Create a
.eslintrc.cjs
extending the config:
const path = require('path');
/** @type {import("eslint").Linter.Config} */
module.exports = {
extends: ['@withyoutecnologia/eslint-config/react'],
parser: '@typescript-eslint/parser',
parserOptions: {
project: path.join(__dirname, 'tsconfig.json')
}
};
- Add the linting scripts
// package.json
"scripts": {
// ...,
"lint": "eslint src --ext ts,tsx",
"lint:fix": "eslint src --ext ts,tsx --fix",
}