@gap-referencement/front-shared-config
v1.0.2
Published
Shared ESLint config for all manager front projets
Maintainers
Readme
All Manager Shared ESLint Configuration
This package provides a shared ESLint configuration for All Manager frontend projects, ensuring consistent code style and best practices across the codebase.
Features
- TypeScript support
- React Hooks rules
- JSX A11y accessibility rules
- Import/export sorting
- Unused imports detection
- Stylistic rules for consistent code style
Installation
- First, install the required peer dependencies in your project:
npm install --save-dev eslint @all-manager/front-shared-config- Create or update your ESLint configuration file (
.eslintrc.jsoreslint.config.js):
// eslint.config.js
import allManagerConfig from '@all-manager/front-shared-config';
export default [
...allManagerConfig,
// Add your project-specific rules here
{
rules: {
// Your custom rules
}
}
];Editor Integration
For the best development experience, we recommend using the following setup:
- Install the ESLint extension for VS Code
- Add the following to your VS Code settings (
.vscode/settings.json):
{
"editor.codeActionsOnSave": {
"source.fixAll.eslint": "explicit"
},
"eslint.validate": ["javascript", "javascriptreact", "typescript", "typescriptreact"]
}Recommended VS Code Extensions
Scripts
Add these scripts to your package.json for convenience:
{
"scripts": {
"lint": "eslint . --ext .js,.jsx,.ts,.tsx",
"lint:fix": "eslint . --ext .js,.jsx,.ts,.tsx --fix"
}
}Versioning
This package follows Semantic Versioning.
License
ISC
