@yonycalsin/eslint-plugin-import-sort
v5.4.5
Published
@yonycalsin/eslint-plugin-import-sort
Downloads
122
Maintainers
Readme
@yonycalsin/eslint-plugin-import-sort
Installation
# Using npm
npm install --save @yonycalsin/eslint-plugin-import-sort@latest
# Using yarn
yarn add @yonycalsin/eslint-plugin-import-sort@latest
Usage
eslintrc.js
Extending configs
// for react
{
extends: ['plugin:@yonycalsin/import-sort/react']
}
// for node
{
extends: ['plugin:@yonycalsin/import-sort/node']
}
Using rules
module.exports = {
plugins: ['@yonycalsin/import-sort'],
rules: {
'@yonycalsin/import-sort/typescript-react-imports': 'error',
'@yonycalsin/import-sort/typescript-react-exports': 'error',
},
}
you can also customize the modules
'@yonycalsin/import-sort/typescript-react-imports': ['error', { modules: ["analytics", "screens", "utils"] }],
Stay in touch
- Github @yonycalsin
- Twitter @yonycalsin
License
@yonycalsin/eslint-plugin-import-sort
under License.