perf: check typescript with eslint

This commit is contained in:
orzyyyy 2019-08-02 17:41:16 +08:00
parent 3a8fcd6281
commit ce124a36f8
2 changed files with 8 additions and 5 deletions

View File

@ -1,5 +1,5 @@
const eslintrc = {
extends: ['airbnb', 'prettier', 'plugin:jest/recommended'],
extends: ['airbnb', 'prettier', 'plugin:jest/recommended', 'plugin:react/recommended'],
env: {
browser: true,
node: true,
@ -7,8 +7,8 @@ const eslintrc = {
jest: true,
es6: true,
},
parser: 'babel-eslint',
plugins: ['markdown', 'react', 'babel', 'jest'],
parser: '@typescript-eslint/parser',
plugins: ['markdown', 'react', 'babel', 'jest', '@typescript-eslint'],
rules: {
'react/jsx-one-expression-per-line': 0,
'react/prop-types': 0,

View File

@ -97,6 +97,7 @@
},
"devDependencies": {
"@ant-design/colors": "^3.1.0",
"@ant-design/tools": "^8.0.0",
"@packtracker/webpack-plugin": "^2.0.1",
"@sentry/browser": "^5.4.0",
"@types/classnames": "^2.2.8",
@ -105,9 +106,10 @@
"@types/react-dom": "^16.8.4",
"@types/react-intl": "^2.3.17",
"@types/warning": "^3.0.0",
"@typescript-eslint/eslint-plugin": "^1.13.0",
"@typescript-eslint/parser": "^1.13.0",
"@yesmeck/offline-plugin": "^5.0.5",
"antd-theme-generator": "^1.1.6",
"@ant-design/tools": "^8.0.0",
"babel-eslint": "^10.0.1",
"babel-plugin-add-react-displayname": "^0.0.5",
"bisheng": "^1.3.0",
@ -125,7 +127,7 @@
"enzyme": "^3.10.0",
"enzyme-adapter-react-16": "^1.14.0",
"enzyme-to-json": "^3.3.5",
"eslint": "^6.0.0",
"eslint": "^6.1.0",
"eslint-config-airbnb": "^17.1.0",
"eslint-config-prettier": "^6.0.0",
"eslint-plugin-babel": "^5.3.0",
@ -204,6 +206,7 @@
"lint-fix:code": "eslint --fix tests site scripts components ./.*.js ./webpack.config.js --ext '.js,.jsx'",
"lint-fix:demo": "eslint-tinker ./components/*/demo/*.md",
"lint-fix:style": "stylelint --fix '{site,components}/**/*.less' --syntax less",
"lint:ts:with-eslint": "eslint components/**/*.tsx",
"sort-api": "antd-tools run sort-api-table",
"api-collection": "antd-tools run api-collection",
"dist": "antd-tools run dist",