xiaohe0601 / github@xiaohe0601 / gitee@xiaohe0601
# pnpm
pnpm add -D eslint @xiaohe01/eslint-config
# yarn
yarn add --dev eslint @xiaohe01/eslint-config
# npm
npm install -D eslint @xiaohe01/eslint-config
[!WARNING] Require Node.js >= 18.18.0, and ESLint >= 9.5.0.
Create eslint.config.mjs
in your project root
import defineConfig from "@xiaohe01/eslint-config";
export default defineConfig();
[!NOTE] If you want to use TypeScript configuration files, please refer to typescript-configuration-files.
Add script for package.json
, for example
{
"scripts": {
"lint": "eslint",
"lint:fix": "eslint --fix"
}
}
For more information, please refer to antfu/eslint-config.
Most of the rules are the same, but there are some differences:
- I prefer to use
""
and;
. - Some different rules for uniapp.
- Maybe stricter and simpler.
- MIT LICENSE