Skip to content

Commit

Permalink
REMOVE tslint, and use eslint for everything
Browse files Browse the repository at this point in the history
  • Loading branch information
ndelangen committed Apr 25, 2019
1 parent a83f1fa commit 3310029
Show file tree
Hide file tree
Showing 5 changed files with 84 additions and 11 deletions.
3 changes: 1 addition & 2 deletions .eslintignore
Original file line number Diff line number Diff line change
Expand Up @@ -7,10 +7,9 @@ docs/public
storybook-static
built-storybooks
lib/cli/test
scripts/storage
*.bundle.js
*.js.map
*.ts
*.tsx

!.remarkrc.js
!.babelrc.js
Expand Down
23 changes: 20 additions & 3 deletions .eslintrc.js
Original file line number Diff line number Diff line change
Expand Up @@ -7,12 +7,29 @@ module.exports = {
'airbnb',
'plugin:jest/recommended',
'plugin:import/react-native',
'plugin:@typescript-eslint/recommended',
'prettier',
'prettier/react',
'prettier/@typescript-eslint',
],
plugins: ['prettier', 'jest', 'import', 'react', 'jsx-a11y', 'json', 'html'],
parser: 'babel-eslint',
parserOptions: { ecmaVersion: 8, sourceType: 'module' },
plugins: [
'@typescript-eslint',
'prettier',
'jest',
'import',
'react',
'jsx-a11y',
'json',
'html',
],
parser: '@typescript-eslint/parser',
parserOptions: {
ecmaVersion: 8,
sourceType: 'module',
ecmaFeatures: {
jsx: true,
},
},
env: { es6: true, node: true, 'jest/globals': true },
settings: {
'import/core-modules': ['enzyme'],
Expand Down
2 changes: 2 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -25,3 +25,5 @@ integration/__image_snapshots__/__diff_output__
lib/*.jar
lib/**/dll
.expo/packager-info.json
scripts/storage
htpasswd
26 changes: 21 additions & 5 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -34,12 +34,11 @@
"docs:build": "npm --prefix docs run build",
"docs:dev": "npm --prefix docs run dev",
"github-release": "github-release-from-changelog",
"lint": "yarn lint:js . && yarn lint:ts **/*.ts **/*.tsx && yarn lint:md .",
"lint:ci": "yarn lint:js --format ./node_modules/eslint-teamcity/index.js . && yarn lint:ts **/*.ts && yarn lint:md .",
"lint:js": "cross-env NODE_ENV=production eslint --cache --cache-location=.cache/eslint --ext .js,.jsx,.json,.html --report-unused-disable-directives",
"lint": "yarn lint:js . && yarn lint:md .",
"lint:ci": "yarn lint:js --format ./node_modules/eslint-teamcity/index.js . && yarn lint:md .",
"lint:js": "cross-env NODE_ENV=production eslint --cache --cache-location=.cache/eslint --ext .js,.jsx,.json,.html,.ts,.tsx,.mjs --report-unused-disable-directives",
"lint:md": "remark -q",
"lint:package": "sort-package-json",
"lint:ts": "tslint -p . -c tslint.json -t stylish",
"publish:crna": "yarn --cwd examples-native/crna-kitchen-sink expo publish",
"publish:debug": "npm run publish:latest -- --npm-tag=debug --no-push",
"publish:latest": "lerna publish --exact --concurrency 1 --force-publish",
Expand All @@ -61,8 +60,24 @@
"yarn lint:js --fix",
"git add"
],
"*.jsx": [
"yarn lint:js --fix",
"git add"
],
"*.mjs": [
"yarn lint:js --fix",
"git add"
],
"*.html": [
"yarn lint:js --fix",
"git add"
],
"*.ts": [
"yarn lint:ts --fix",
"yarn lint:js --fix",
"git add"
],
"*.tsx": [
"yarn lint:js --fix",
"git add"
],
"*.json": [
Expand All @@ -78,6 +93,7 @@
"browserslist": "defaults",
"dependencies": {
"@babel/plugin-syntax-dynamic-import": "^7.2.0",
"@typescript-eslint/eslint-plugin": "^1.7.0",
"babel-plugin-add-react-displayname": "^0.0.5",
"eslint-plugin-html": "^5.0.3",
"jest-matcher-utils": "^24.7.0",
Expand Down
41 changes: 40 additions & 1 deletion yarn.lock
Original file line number Diff line number Diff line change
Expand Up @@ -3259,6 +3259,35 @@
resolved "https://registry.yarnpkg.com/@types/yargs/-/yargs-12.0.12.tgz#45dd1d0638e8c8f153e87d296907659296873916"
integrity sha512-SOhuU4wNBxhhTHxYaiG5NY4HBhDIDnJF60GU+2LqHAdKKer86//e4yg69aENCtQ04n0ovz+tq2YPME5t5yp4pw==

"@typescript-eslint/eslint-plugin@^1.7.0":
version "1.7.0"
resolved "https://registry.npmjs.org/@typescript-eslint/eslint-plugin/-/eslint-plugin-1.7.0.tgz#570e45dc84fb97852e363f1e00f47e604a0b8bcc"
integrity sha512-NUSz1aTlIzzTjFFVFyzrbo8oFjHg3K/M9MzYByqbMCxeFdErhLAcGITVfXzSz+Yvp5OOpMu3HkIttB0NyKl54Q==
dependencies:
"@typescript-eslint/parser" "1.7.0"
"@typescript-eslint/typescript-estree" "1.7.0"
eslint-utils "^1.3.1"
regexpp "^2.0.1"
requireindex "^1.2.0"
tsutils "^3.7.0"

"@typescript-eslint/[email protected]":
version "1.7.0"
resolved "https://registry.npmjs.org/@typescript-eslint/parser/-/parser-1.7.0.tgz#c3ea0d158349ceefbb6da95b5b09924b75357851"
integrity sha512-1QFKxs2V940372srm12ovSE683afqc1jB6zF/f8iKhgLz1yoSjYeGHipasao33VXKI+0a/ob9okeogGdKGvvlg==
dependencies:
"@typescript-eslint/typescript-estree" "1.7.0"
eslint-scope "^4.0.0"
eslint-visitor-keys "^1.0.0"

"@typescript-eslint/[email protected]":
version "1.7.0"
resolved "https://registry.npmjs.org/@typescript-eslint/typescript-estree/-/typescript-estree-1.7.0.tgz#59ec02f5371964da1cc679dba7b878a417bc8c60"
integrity sha512-K5uedUxVmlYrVkFbyV3htDipvLqTE3QMOUQEHYJaKtgzxj6r7c5Ca/DG1tGgFxX+fsbi9nDIrf4arq7Ib7H/Yw==
dependencies:
lodash.unescape "4.0.1"
semver "5.5.0"

"@vue/component-compiler-utils@^2.5.1":
version "2.6.0"
resolved "https://registry.yarnpkg.com/@vue/component-compiler-utils/-/component-compiler-utils-2.6.0.tgz#aa46d2a6f7647440b0b8932434d22f12371e543b"
Expand Down Expand Up @@ -16837,6 +16866,11 @@ lodash.throttle@^4.1.1:
resolved "https://registry.yarnpkg.com/lodash.throttle/-/lodash.throttle-4.1.1.tgz#c23e91b710242ac70c37f1e1cda9274cc39bf2f4"
integrity sha1-wj6RtxAkKscMN/HhzaknTMOb8vQ=

[email protected]:
version "4.0.1"
resolved "https://registry.npmjs.org/lodash.unescape/-/lodash.unescape-4.0.1.tgz#bf2249886ce514cda112fae9218cdc065211fc9c"
integrity sha1-vyJJiGzlFM2hEvrpIYzcBlIR/Jw=

lodash.uniq@^4.2.0, lodash.uniq@^4.5.0:
version "4.5.0"
resolved "https://registry.yarnpkg.com/lodash.uniq/-/lodash.uniq-4.5.0.tgz#d0225373aeb652adc1bc82e4945339a842754773"
Expand Down Expand Up @@ -22933,6 +22967,11 @@ require-self-ref@^2.0.1:
dependencies:
lasso-package-root "^1.0.0"

requireindex@^1.2.0:
version "1.2.0"
resolved "https://registry.npmjs.org/requireindex/-/requireindex-1.2.0.tgz#3463cdb22ee151902635aa6c9535d4de9c2ef1ef"
integrity sha512-L9jEkOi3ASd9PYit2cwRfyppc9NoABujTP8/5gFcbERmo5jUoAKovIC3fsF17pkTnGsrByysqX+Kxd2OTNI1ww==

requires-port@^1.0.0:
version "1.0.0"
resolved "https://registry.yarnpkg.com/requires-port/-/requires-port-1.0.0.tgz#925d2601d39ac485e091cf0da5c6e694dc3dcaff"
Expand Down Expand Up @@ -25736,7 +25775,7 @@ tsutils@^2.29.0:
dependencies:
tslib "^1.8.1"

tsutils@^3.0.0, tsutils@^3.5.0:
tsutils@^3.0.0, tsutils@^3.5.0, tsutils@^3.7.0:
version "3.10.0"
resolved "https://registry.yarnpkg.com/tsutils/-/tsutils-3.10.0.tgz#6f1c95c94606e098592b0dff06590cf9659227d6"
integrity sha512-q20XSMq7jutbGB8luhKKsQldRKWvyBO2BGqni3p4yq8Ys9bEP/xQw3KepKmMRt9gJ4lvQSScrihJrcKdKoSU7Q==
Expand Down

0 comments on commit 3310029

Please sign in to comment.