Skip to content

Commit 85afd03

Browse files
committed
fix eslint config
1 parent 638a222 commit 85afd03

3 files changed

Lines changed: 20 additions & 12 deletions

File tree

.eslintrc.js

Lines changed: 17 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -4,27 +4,34 @@ module.exports = {
44
ecmaVersion: 2020,
55
sourceType: 'module',
66
ecmaFeatures: {
7-
jsx: true
8-
}
7+
jsx: true,
8+
},
99
},
1010
settings: {
1111
react: {
12-
version: 'detect'
13-
}
12+
version: 'detect',
13+
},
1414
},
1515
env: {
1616
jest: true,
1717
browser: true,
1818
amd: true,
19-
node: true
19+
node: true,
2020
},
2121
extends: [
2222
'eslint:recommended',
2323
'plugin:react/recommended',
24-
'plugin:prettier/recommended' // Make this the last element so prettier config overrides other formatting rules
24+
'plugin:prettier/recommended', // Make this the last element so prettier config overrides other formatting rules
2525
],
2626
rules: {
27-
'no-unused-vars': ['error', { vars: 'all', args: 'after-used', ignoreRestSiblings: false }],
28-
'prettier/prettier': ['error', {}, { usePrettierrc: true }]
29-
}
30-
}
27+
'no-unused-vars': [
28+
'error',
29+
{ vars: 'all', args: 'after-used', ignoreRestSiblings: false },
30+
],
31+
'prettier/prettier': [
32+
'error',
33+
{ endOfLine: 'auto' },
34+
{ usePrettierrc: true },
35+
],
36+
},
37+
};

.prettierrc

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,5 +4,6 @@
44
"useTabs": false,
55
"semi": true,
66
"singleQuote": true,
7-
"trailingComma": "all"
7+
"trailingComma": "all",
8+
"endOfLine": "auto"
89
}

src/components/App.jsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
import React from "react";
1+
import React from 'react';
22

33
const App = () => {
44
return <div>App</div>;

0 commit comments

Comments
 (0)