Skip to content

Commit 4a367f2

Browse files
committed
Add rules
1 parent 21f0970 commit 4a367f2

File tree

5 files changed

+209
-3
lines changed

5 files changed

+209
-3
lines changed

.editorconfig

+15
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
# EditorConfig helps developers define and maintain consistent
2+
# coding styles between different editors and IDEs
3+
# editorconfig.org
4+
5+
root = true
6+
7+
[*]
8+
end_of_line = LF
9+
charset = utf-8
10+
max_line_length = 120
11+
indent_style = space
12+
indent_size = 2
13+
insert_final_newline = true
14+
trim_trailing_whitespace = true
15+

.gitignore

+1
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
node_modules

index.js

+38
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,40 @@
11
module.exports = {
2+
configs: {
3+
recommended: {
4+
parserOptions: {
5+
ecmaVersion: 2019
6+
},
7+
env: {
8+
node: true
9+
},
10+
extends: ['airbnb', 'prettier'],
11+
plugins: [
12+
'node'
13+
],
14+
rules: {
15+
"no-process-exit": "error",
16+
"node/exports-style": "off",
17+
"node/no-deprecated-api": "error",
18+
"node/no-extraneous-import": "off",
19+
"node/no-extraneous-require": "error",
20+
"node/no-missing-import": "off",
21+
"node/no-missing-require": "error",
22+
"node/no-unpublished-bin": "error",
23+
"node/no-unpublished-import": "off",
24+
"node/no-unpublished-require": "error",
25+
"node/no-unsupported-features/es-builtins": "error",
26+
"node/no-unsupported-features/es-syntax": "error",
27+
"node/no-unsupported-features/node-builtins": "error",
28+
"node/prefer-global/buffer": "off",
29+
"node/prefer-global/console": "off",
30+
"node/prefer-global/process": "off",
31+
"node/prefer-global/text-decoder": "off",
32+
"node/prefer-global/text-encoder": "off",
33+
"node/prefer-global/url-search-params": "off",
34+
"node/prefer-global/url": "off",
35+
"node/process-exit-as-throw": "error",
36+
"node/shebang": "error"
37+
}
38+
}
39+
}
240
};

package-lock.json

+148
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

+7-3
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "eslint-plugin-solfegejs",
3-
"version": "8.0.1",
3+
"version": "1.0.0",
44
"author": "neolao <[email protected]>",
55
"description": "Additional ESLint's rules for Node.js",
66
"repository": "https://github.com/solfegejs/eslint-plugin.git",
@@ -20,6 +20,10 @@
2020
"eslintplugin",
2121
"eslint-plugin",
2222
"node",
23-
"nodejs",
24-
]
23+
"nodejs"
24+
],
25+
"dependencies": {
26+
"eslint-config-airbnb": "^17.1.0",
27+
"eslint-config-prettier": "^4.0.0"
28+
}
2529
}

0 commit comments

Comments
 (0)