@teslao/eslint-config-rax

0.0.1 • Public • Published

安装

npm install eslint-config-rax

依赖的库有:

  // 基础依赖
  "babel-eslint": "^10.0.1"
  "eslint": "^5.16.0"
  "eslint-plugin-import": "^2.17.2"
  // 使用Typescript时依赖
  "@typescript-eslint/eslint-plugin": "^1.7.0"
  "@typescript-eslint/parser": "^1.7.0"
  "typescript": "^3.4.5"
  // 使用React时依赖
  "eslint-plugin-react": "^7.12.4"

使用

设置 .eslintrc.js 内容如下:

规则定义说明

修改规则

若修改增添规则,请提供规则的用处和理由

比如:

    /**
     * Indent is replaced by two Spaces
     * @reason Conventional convention
    */
    "indent": "off",
    '@typescript-eslint/indent': [
      'error',
      2,
      {
        SwitchCase: 1,
        flatTernaryExpressions: true
      }
    ],

Readme

Keywords

Package Sidebar

Install

npm i @teslao/eslint-config-rax

Weekly Downloads

1

Version

0.0.1

License

BSD-3-Clause

Unpacked Size

12.1 kB

Total Files

16

Last publish

Collaborators

  • wangda95