eslint-config-tenx
v4.0.0
Published
eslint config for tenxcloud
Downloads
2
Readme
eslint-config-tenx
Lint js and ts with one config 🆒
based on eslint-config-egg and eslint-config-react-app
Usage
最新 4.x 版本只支持 [email protected],如果要兼容老的 eslint,请使用 3.x 及之前的版本
First, install this package, ESLint and the necessary plugins.
ni -D eslint-config-tenx [email protected] [email protected]
注意:升级后需要在 .babelrc
插件配置中添加 ["@babel/plugin-proposal-decorators", { "legacy": true }]
才能支持装饰器 Decorator 的解析
Then create a file named .eslintrc.json(or .eslintrc) with following contents in the root folder of your project:
{
"extends": "tenx"
}
Usage with IDE
vscode
First, install Eslint extension.
Name: ESLint
Id: dbaeumer.vscode-eslint
Description: Integrates ESLint JavaScript into VS Code.
Publisher: Dirk Baeumer
VS Marketplace Link: https://marketplace.visualstudio.com/items?itemName=dbaeumer.vscode-eslint
Then change settings and disable Tslint extension:
"eslint.validate": [
"javascript",
"javascriptreact",
"typescript",
"typescriptreact"
]