eslint-config-airbnb-extended 0.5.1 → 0.5.2
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/dist/@types/index.d.ts
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
* Direct export not allowed, it will increase the size of d.ts
|
|
3
3
|
*/
|
|
4
4
|
export declare const rules: {
|
|
5
|
-
base: Record<"
|
|
5
|
+
base: Record<"bestPractices" | "errors" | "es6" | "imports" | "node" | "strict" | "style" | "stylistic" | "variables" | "importsStrict" | "reactStrict", import("eslint").Linter.Config>;
|
|
6
6
|
react: Record<"react" | "reactA11y" | "reactHooks", import("eslint").Linter.Config>;
|
|
7
7
|
next: Record<"next", import("eslint").Linter.Config>;
|
|
8
8
|
typescript: Record<"imports" | "base" | "typescriptEslint", import("eslint").Linter.Config>;
|
|
@@ -3,11 +3,11 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
|
3
3
|
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
4
4
|
};
|
|
5
5
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
|
-
const
|
|
6
|
+
const next_1 = __importDefault(require("../../configs/next"));
|
|
7
7
|
const recommended_1 = __importDefault(require("../../configs/react/recommended"));
|
|
8
8
|
const nextRecommendedConfig = [
|
|
9
9
|
...recommended_1.default,
|
|
10
|
-
...Object.values(
|
|
10
|
+
...Object.values(next_1.default),
|
|
11
11
|
{
|
|
12
12
|
name: 'airbnb/config/next-import-x',
|
|
13
13
|
files: ['**/app/**/route.ts', '**/middleware.ts'],
|
|
@@ -15,5 +15,12 @@ const nextRecommendedConfig = [
|
|
|
15
15
|
'import-x/prefer-default-export': 'off',
|
|
16
16
|
},
|
|
17
17
|
},
|
|
18
|
+
{
|
|
19
|
+
name: 'airbnb/config/next-react-jsx-runtime',
|
|
20
|
+
rules: {
|
|
21
|
+
'react/jsx-uses-react': 'off',
|
|
22
|
+
'react/react-in-jsx-scope': 'off',
|
|
23
|
+
},
|
|
24
|
+
},
|
|
18
25
|
];
|
|
19
26
|
exports.default = nextRecommendedConfig;
|
package/dist/rules/react.js
CHANGED
|
@@ -3,14 +3,6 @@ Object.defineProperty(exports, "__esModule", { value: true });
|
|
|
3
3
|
const reactStrictRules = {
|
|
4
4
|
name: 'airbnb/config/react/strict',
|
|
5
5
|
rules: {
|
|
6
|
-
// Enforces consistent naming for boolean props
|
|
7
|
-
// https://github.com/jsx-eslint/eslint-plugin-react/blob/master/docs/rules/boolean-prop-naming.md
|
|
8
|
-
'react/boolean-prop-naming': [
|
|
9
|
-
'error',
|
|
10
|
-
{
|
|
11
|
-
validateNested: true,
|
|
12
|
-
},
|
|
13
|
-
],
|
|
14
6
|
// This rule enforces onChange or readonly attribute for checked property of input elements.
|
|
15
7
|
// https://github.com/jsx-eslint/eslint-plugin-react/blob/master/docs/rules/checked-requires-onchange-or-readonly.md
|
|
16
8
|
'react/checked-requires-onchange-or-readonly': 'error',
|