Skip to content

Commit 683ee6b

Browse files
committed
add shareable eslint config
1 parent 43810eb commit 683ee6b

File tree

2 files changed

+24
-1
lines changed

2 files changed

+24
-1
lines changed

config/.eslintrc.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,3 @@
11
{
2-
"extends": [ "plugin:@wordpress/eslint-plugin/recommended" ]
2+
"extends": "../eslint-config"
33
}

eslint-config.js

+23
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,23 @@
1+
module.exports = {
2+
extends: ['plugin:@wordpress/eslint-plugin/recommended'],
3+
parserOptions: {
4+
requireConfigFile: false,
5+
},
6+
rules: {
7+
'prettier/prettier': [
8+
'error',
9+
{
10+
useTabs: true,
11+
tabWidth: 4,
12+
printWidth: 80,
13+
singleQuote: true,
14+
trailingComma: 'es5',
15+
bracketSpacing: true,
16+
parenSpacing: false,
17+
bracketSameLine: false,
18+
semi: true,
19+
arrowParens: 'always',
20+
},
21+
],
22+
},
23+
};

0 commit comments

Comments
 (0)