eslint-config-reverentgeek 5.0.4 → 5.2.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +26 -0
- package/index.js +2 -1
- package/package.json +2 -2
- package/react.js +12 -0
package/README.md
CHANGED
|
@@ -79,6 +79,32 @@ export default [
|
|
|
79
79
|
];
|
|
80
80
|
```
|
|
81
81
|
|
|
82
|
+
The _react_ config adds specific support for React, browser, and ES modules (`import`/`export`).
|
|
83
|
+
|
|
84
|
+
```sh
|
|
85
|
+
npm install --save-dev eslint-plugin-react
|
|
86
|
+
```
|
|
87
|
+
|
|
88
|
+
```js
|
|
89
|
+
import rg from "eslint-config-reverentgeek";
|
|
90
|
+
import react from "eslint-plugin-react";
|
|
91
|
+
|
|
92
|
+
export default [
|
|
93
|
+
...rg.configs.browser,
|
|
94
|
+
...rg.configs.react,
|
|
95
|
+
{
|
|
96
|
+
plugins: {
|
|
97
|
+
react,
|
|
98
|
+
},
|
|
99
|
+
rules: {
|
|
100
|
+
"n/no-unpublished-import": [ "error", {
|
|
101
|
+
allowModules: [ "eslint-config-reverentgeek" ]
|
|
102
|
+
} ]
|
|
103
|
+
}
|
|
104
|
+
}
|
|
105
|
+
];
|
|
106
|
+
```
|
|
107
|
+
|
|
82
108
|
The _browser_ config sets the `browser` environment and adds ES module support.
|
|
83
109
|
|
|
84
110
|
```js
|
package/index.js
CHANGED
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "eslint-config-reverentgeek",
|
|
3
|
-
"version": "5.0
|
|
3
|
+
"version": "5.2.0",
|
|
4
4
|
"description": "ESLint rules that ReverentGeek likes :)",
|
|
5
5
|
"main": "index.js",
|
|
6
6
|
"repository": {
|
|
@@ -25,4 +25,4 @@
|
|
|
25
25
|
"devDependencies": {
|
|
26
26
|
"eslint": "^9.1.1"
|
|
27
27
|
}
|
|
28
|
-
}
|
|
28
|
+
}
|