Skip to content
This repository was archived by the owner on Mar 29, 2020. It is now read-only.

Commit 0c7e049

Browse files
committed
feat(deps): upgrade to latest
BREAKING CHANGE: new rules for typescript and react
1 parent ebcaac2 commit 0c7e049

File tree

5 files changed

+849
-280
lines changed

5 files changed

+849
-280
lines changed

.gitignore

Lines changed: 7 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,13 @@
11
# macOS
2+
#
23
.DS_Store
34

45
# node.js
5-
# https://www.npmjs.org/doc/misc/npm-faq.html#should-i-check-my-node_modules-folder-into-git
6+
#
67
node_modules/
8+
npm-debug.log
9+
yarn-error.log
710

8-
# Logs
9-
*.log
10-
11-
# Private environment variables
12-
.env.github-releaser
11+
# ESLint
12+
#
13+
.eslintcache

package.json

Lines changed: 32 additions & 23 deletions
Original file line numberDiff line numberDiff line change
@@ -33,21 +33,30 @@
3333
"scripts": {
3434
"lint": "eslint .",
3535
"lint:fix": "eslint --cache --fix .",
36-
"find-new-rules:babel": "eslint-find-rules --unused ./test/fixtures/babel.js",
36+
"find-new-rules:babel":
37+
"eslint-find-rules --unused ./test/fixtures/babel.js",
3738
"find-new-rules:base": "eslint-find-rules --unused ./index.js",
38-
"find-new-rules:flowtype": "eslint-find-rules --unused ./test/fixtures/flowtype.js",
39+
"find-new-rules:flowtype":
40+
"eslint-find-rules --unused ./test/fixtures/flowtype.js",
3941
"find-new-rules:jest": "eslint-find-rules --unused ./test/fixtures/jest.js",
40-
"find-new-rules:lodash": "eslint-find-rules --unused ./test/fixtures/lodash.js",
41-
"find-new-rules:react-native": "eslint-find-rules --unused ./test/fixtures/react-native.js",
42-
"find-new-rules:react": "eslint-find-rules --unused ./test/fixtures/react.js",
43-
"find-new-rules:typescript": "eslint-find-rules --unused ./test/fixtures/typescript.js",
42+
"find-new-rules:lodash":
43+
"eslint-find-rules --unused ./test/fixtures/lodash.js",
44+
"find-new-rules:react-native":
45+
"eslint-find-rules --unused ./test/fixtures/react-native.js",
46+
"find-new-rules:react":
47+
"eslint-find-rules --unused ./test/fixtures/react.js",
48+
"find-new-rules:typescript":
49+
"eslint-find-rules --unused ./test/fixtures/typescript.js",
4450
"find-new-rules": "run-p --silent find-new-rules:*",
45-
"prettier-check": "eslint --print-config index.js | eslint-config-prettier-check",
51+
"prettier-check":
52+
"eslint --print-config index.js | eslint-config-prettier-check",
4653
"jest": "jest",
4754
"test": "run-p --silent lint find-new-rules prettier-check jest",
55+
"precommit": "lint-staged",
4856
"commitmsg": "validate-commit-msg",
4957
"prepush": "yarn test",
50-
"semantic-release": "semantic-release pre && npm publish && semantic-release post"
58+
"semantic-release":
59+
"semantic-release pre && npm publish && semantic-release post"
5160
},
5261
"lint-staged": {
5362
"{*.js,{rules,test}/**/*.js}": ["eslint --cache --fix", "git add"],
@@ -70,33 +79,33 @@
7079
},
7180
"dependencies": {
7281
"babel-eslint": "^7.2.3",
73-
"eslint-config-airbnb-base": "^11.3.1",
74-
"eslint-config-prettier": "^2.1.1",
82+
"eslint-config-airbnb-base": "^12.0.0",
83+
"eslint-config-prettier": "^2.4.0",
7584
"eslint-plugin-babel": "^4.1.2",
7685
"eslint-plugin-eslint-comments": "^1.0.3",
77-
"eslint-plugin-flowtype": "^2.35.0",
86+
"eslint-plugin-flowtype": "^2.35.1",
7887
"eslint-plugin-import": "^2.7.0",
79-
"eslint-plugin-jest": "^20.0.3",
88+
"eslint-plugin-jest": "^21.0.0",
8089
"eslint-plugin-jsx-a11y": "^6.0.2",
8190
"eslint-plugin-lodash-fp": "^2.1.3",
8291
"eslint-plugin-no-use-extend-native": "^0.3.12",
83-
"eslint-plugin-prettier": "^2.1.1",
92+
"eslint-plugin-prettier": "^2.2.0",
8493
"eslint-plugin-promise": "^3.5.0",
85-
"eslint-plugin-react": "^7.0.1",
86-
"eslint-plugin-react-native": "^3.0.1",
87-
"eslint-plugin-typescript": "^0.3.0",
94+
"eslint-plugin-react": "^7.3.0",
95+
"eslint-plugin-react-native": "^3.1.0",
96+
"eslint-plugin-typescript": "^0.7.0",
8897
"eslint-plugin-unicorn": "^2.1.1",
89-
"typescript-eslint-parser": "^4.0.0"
98+
"typescript-eslint-parser": "^8.0.0"
9099
},
91100
"devDependencies": {
92-
"eslint": "^4.3.0",
101+
"eslint": "^4.6.1",
93102
"eslint-find-rules": "^3.1.1",
94103
"husky": "^0.14.3",
95-
"jest": "^20.0.4",
96-
"lint-staged": "^4.0.2",
97-
"npm-run-all": "^4.0.2",
98-
"prettier": "^1.5.3",
99-
"semantic-release": "^6.3.6",
104+
"jest": "^21.0.1",
105+
"lint-staged": "^4.1.1",
106+
"npm-run-all": "^4.1.1",
107+
"prettier": "^1.6.1",
108+
"semantic-release": "^7.0.2",
100109
"validate-commit-msg": "^2.14.0"
101110
}
102111
}

react-base.js

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -28,6 +28,7 @@ module.exports = {
2828
'jsx-quotes': ['error', 'prefer-double'],
2929
'no-unused-expressions': ['error', {allowShortCircuit: true}],
3030
// https://github.com/yannickcr/eslint-plugin-react
31+
'react/boolean-prop-naming': 'off',
3132
'react/default-props-match-prop-types': 'error',
3233
'react/display-name': 'error',
3334
'react/forbid-component-props': 'off',
@@ -72,9 +73,11 @@ module.exports = {
7273
'react/no-render-return-value': 'error',
7374
'react/no-set-state': 'off',
7475
'react/no-string-refs': 'error',
76+
'react/no-typos': 'error',
7577
'react/no-unescaped-entities': 'error',
7678
'react/no-unknown-property': 'error',
7779
'react/no-unused-prop-types': 'off',
80+
'react/no-unused-state': 'error',
7881
'react/no-will-update-set-state': 'error',
7982
'react/prefer-es6-class': ['error', 'always'],
8083
'react/prefer-stateless-function': 'error',

typescript.js

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -56,13 +56,24 @@ module.exports = {
5656
},
5757
],
5858
// https://github.com/nzakas/eslint-plugin-typescript
59+
'typescript/adjacent-overload-signatures': 'error',
60+
'typescript/class-name-casing': 'error',
5961
'typescript/explicit-member-accessibility': 'error',
6062
'typescript/interface-name-prefix': 'error',
63+
'typescript/member-delimiter-style': 'off',
64+
'typescript/member-ordering': 'error',
6165
'typescript/no-angle-bracket-type-assertion': 'error',
66+
'typescript/no-empty-interface': 'error',
6267
'typescript/no-explicit-any': 'error',
6368
'typescript/no-namespace': ['error', {allowDefinitionFiles: true}],
69+
'typescript/no-parameter-properties': 'off',
6470
'typescript/no-triple-slash-reference': 'error',
71+
'typescript/no-type-alias': 'off',
6572
'typescript/no-unused-vars': 'error',
73+
'typescript/no-use-before-define': [
74+
'error',
75+
{functions: true, classes: true, variables: true},
76+
],
6677
'typescript/prefer-namespace-keyword': 'error',
6778
'typescript/type-annotation-spacing': 'off',
6879
},

0 commit comments

Comments
 (0)