This package provides MI's .eslintrc as an extensible shared config.
- Install library via command
yarn add eslint-config-mi-react -D
- Install peer dependencies
npx install-peerdeps eslint-config-mi-react --dev -Y
To enable this configuration to your project, create a .eslintrc
file in the root of your project.
Add "extends": "eslint-config-mi-react"
to your .eslintrc
, e.g.:
{
"extends": "eslint-config-mi-react"
}
Create a .prettierrc.js
file in the root of your project. Import prettier rules and export from file.
const defaultConfigs = require('eslint-config-mi-react/prettierrc');
module.exports = {
...defaultConfigs,
};
Create a .babelrc.js
file in the root of your project. Import babel configs and export from file.
const { presets } = require('eslint-config-mi-react/babelrc');
module.exports = {
presets: [...presets],
};