Skip to content

Commit c2011ca

Browse files
authored
Don't lint the dist/ and es/ folders (#1329)
* Don't lint the dist/ and es/ folders Move the exlude patterns to .eslint * fix prettier * use the proper parser for prettier
1 parent e601d81 commit c2011ca

File tree

5 files changed

+226
-5671
lines changed

5 files changed

+226
-5671
lines changed

.eslintrc

+22-15
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,23 @@
11
{
2+
"extends": [
3+
"eslint:recommended",
4+
"plugin:react/recommended",
5+
"prettier",
6+
"prettier/react"
7+
],
8+
"parser": "babel-eslint",
9+
"plugins": [
10+
"react",
11+
"prettier",
12+
"babel",
13+
"no-only-tests"
14+
],
15+
"ignorePatterns": [
16+
"node_modules",
17+
"bundle.js",
18+
"**/dist/",
19+
"**/es/"
20+
],
221
"settings":{
322
"react":{
423
"version": "detect"
@@ -8,26 +27,14 @@
827
"es6": true,
928
"browser": true
1029
},
11-
"extends": [
12-
"eslint:recommended",
13-
"prettier",
14-
"prettier/react",
15-
"plugin:react/recommended"
16-
],
1730
"rules": {
1831
"consistent-return": 0,
1932
"max-len": [1, 110, 4],
2033
"max-params": ["error", 6],
2134
"object-curly-spacing": 0,
2235
"babel/object-curly-spacing": 2,
2336
"no-only-tests/no-only-tests": 2,
24-
"react/prop-types": "off"
25-
},
26-
"parser": "babel-eslint",
27-
"plugins": [
28-
"react",
29-
"babel",
30-
"prettier",
31-
"no-only-tests"
32-
]
37+
"react/prop-types": "off",
38+
"prettier/prettier": "warn"
39+
}
3340
}

.prettierrc

+1-1
Original file line numberDiff line numberDiff line change
@@ -4,5 +4,5 @@
44
"bracketSpacing": false,
55
"jsxBracketSameLine": false,
66
"semi": true,
7-
"parser": "babylon"
7+
"parser": "babel"
88
}

package.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@
2626
"es6",
2727
"babel"
2828
],
29-
"scripts":{
29+
"scripts": {
3030
"remove-unpm-rfs": "./remove-refs-to-unpm.pl"
3131
},
3232
"devDependencies": {

packages/react-vis/package.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@
2525
"start": "(cd showcase && command -v yarn >/dev/null && yarn && npm start || npm install && npm start)",
2626
"build:browser": "browserify src/index.js -t [ babelify ] --standalone reactVis | uglifyjs > dist/dist.min.js",
2727
"build": "yarn run clean && babel src -d dist --copy-files && BABEL_ENV=es babel src -d es --copy-files && node-sass src/main.scss dist/style.css --output-style compressed && yarn run build:browser",
28-
"lint": "eslint . --ignore-pattern node_modules --ignore-pattern bundle.js",
28+
"lint": "eslint .",
2929
"lint-styles": "stylelint src/styles/*.scss --syntax scss",
3030
"test:windows": "babel-node --inspect ./tests/index.js",
3131
"test": "node --inspect ./node_modules/.bin/babel-node ./tests/index.js",

0 commit comments

Comments
 (0)