# eslint-plugin-test **Repository Path**: yangliying/eslint-plugin-test ## Basic Information - **Project Name**: eslint-plugin-test - **Description**: No description available - **Primary Language**: Unknown - **License**: Not specified - **Default Branch**: master - **Homepage**: None - **GVP Project**: No ## Statistics - **Stars**: 0 - **Forks**: 0 - **Created**: 2024-03-04 - **Last Updated**: 2024-03-05 ## Categories & Tags **Categories**: Uncategorized **Tags**: None ## README # eslint-plugin-lint eslint自定义插件 ## Installation You'll first need to install [ESLint](https://eslint.org/): ```sh npm i eslint --save-dev ``` Next, install `eslint-plugin-lint`: ```sh npm install eslint-plugin-lint --save-dev ``` Next install 配置依赖插件 ```sh npm install -D eslint-plugin-import eslint-plugin-jsx-a11y eslint-plugin-react eslint-plugin-react-hooks @typescript-eslint/parser @typescript-eslint/eslint-plugin ``` ## Usage Add `lint` to the plugins section of your `.eslintrc` configuration file. You can omit the `eslint-plugin-` prefix: ```json { "plugins": [ "lint" ] } ``` Then configure the rules you want to use under the rules section. ```json { "rules": { "lint/rule-name": 2 } } ``` ## Configurations TODO: Run eslint-doc-generator to generate the configs list (or delete this section if no configs are offered). ## Rules TODO: Run eslint-doc-generator to generate the rules list. ## 参考文档 - [eslint自定义规则](https://zh-hans.eslint.org/docs/latest/extend/custom-rules) - [eslint创建插件](https://zh-hans.eslint.org/docs/latest/extend/plugins#%E6%8F%92%E4%BB%B6%E4%B8%AD%E7%9A%84%E9%85%8D%E7%BD%AE)