Personal ESlint config forked from Remix to support non-remix environments.
First, install this package along with ESLint in your project. This package requires at least version 8.1 of ESLint
npm install -D eslint @rileytomasek/eslint-config
Then create a file named .eslintrc.js
in the root of your project:
module.exports = {
extends: [
"@rileytomasek/eslint-config",
"@rileytomasek/eslint-config/node",
]
};
Then create a file named .eslintrc.js
in the root of your project:
module.exports = {
extends: [
"@rileytomasek/eslint-config",
"@rileytomasek/eslint-config/react",
]
};
Please note that because this ruleset is optional, we do not include the core libraries as peer dependencies for this package. If you use these rules, be sure that you have the following dependencies installed in your project:
{
"dependencies": {
"react": "*",
}
}
This packages also ships with optional configuration options for projects that use Jest. To enable these rules, add the following to your .eslintrc
:
module.exports = {
extends: [
"@rileytomasek/eslint-config",
"@rileytomasek/eslint-config/jest",
],
};
Please note that because this ruleset is optional, we do not include the core libraries as peer dependencies for this package. If you use these rules, be sure that you have the following dependencies installed in your project:
{
"dependencies": {
"jest": ">=26.0.0"
}
}