@jimmy.codes/eslint-config 7.6.0 → 7.6.1
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/globs.d.mts
CHANGED
|
@@ -10,6 +10,7 @@ declare const GLOB_TYPE_TESTS: readonly ["**/*.test-d.?([cm])ts", "**/*.test-d.?
|
|
|
10
10
|
declare const GLOB_PLAYWRIGHT: readonly ["**/e2e/**/*.spec.?([cm])[jt]s?(x)", "**/e2e/**/*.test.?([cm])[jt]s?(x)"];
|
|
11
11
|
declare const GLOB_E2E: readonly ["**/e2e/**/*.spec.?([cm])[jt]s?(x)", "**/e2e/**/*.test.?([cm])[jt]s?(x)", "**/cypress/**/*.spec.?([cm])[jt]s?(x)", "**/cypress/**/*.test.?([cm])[jt]s?(x)"];
|
|
12
12
|
declare const GLOB_NEXTJS: readonly ["**/*.?([cm])js", "**/*.?([cm])jsx", "**/*.?([cm])ts", "**/*.?([cm])tsx"];
|
|
13
|
+
declare const GLOB_NEXTJS_ENV: readonly ["**/next-env.d.ts"];
|
|
13
14
|
declare const GLOB_IGNORES: readonly ["**/node_modules", "**/dist", "**/package-lock.json", "**/yarn.lock", "**/pnpm-lock.yaml", "**/bun.lockb", "**/output", "**/coverage", "**/temp", "**/.temp", "**/tmp", "**/.tmp", "**/.history", "**/.vitepress/cache", "**/.nuxt", "**/.next", "**/.vercel", "**/.changeset", "**/.idea", "**/.cache", "**/.output", "**/.vite-inspect", "**/.yarn", "**/storybook-static", "**/.eslint-config-inspector", "**/playwright-report", "**/.astro", "**/.vinxi", "**/app.config.timestamp_*.js", "**/.tanstack", "**/.nitro", "**/CHANGELOG*.md", "**/*.min.*", "**/LICENSE*", "**/__snapshots__", "**/auto-import?(s).d.ts", "**/components.d.ts", "**/vite.config.ts.*.mjs", "**/*.gen.*", "!.storybook"];
|
|
14
15
|
//#endregion
|
|
15
|
-
export { GLOB_ASTRO, GLOB_CJS, GLOB_E2E, GLOB_IGNORES, GLOB_JS, GLOB_JSX, GLOB_NEXTJS, GLOB_PLAYWRIGHT, GLOB_TESTS, GLOB_TS, GLOB_TSX, GLOB_TYPE_TESTS };
|
|
16
|
+
export { GLOB_ASTRO, GLOB_CJS, GLOB_E2E, GLOB_IGNORES, GLOB_JS, GLOB_JSX, GLOB_NEXTJS, GLOB_NEXTJS_ENV, GLOB_PLAYWRIGHT, GLOB_TESTS, GLOB_TS, GLOB_TSX, GLOB_TYPE_TESTS };
|
package/dist/globs.mjs
CHANGED
|
@@ -33,6 +33,7 @@ const GLOB_NEXTJS = [
|
|
|
33
33
|
GLOB_TS,
|
|
34
34
|
GLOB_TSX
|
|
35
35
|
];
|
|
36
|
+
const GLOB_NEXTJS_ENV = ["**/next-env.d.ts"];
|
|
36
37
|
const GLOB_IGNORES = [
|
|
37
38
|
"**/node_modules",
|
|
38
39
|
"**/dist",
|
|
@@ -76,4 +77,4 @@ const GLOB_IGNORES = [
|
|
|
76
77
|
"!.storybook"
|
|
77
78
|
];
|
|
78
79
|
//#endregion
|
|
79
|
-
export { GLOB_ASTRO, GLOB_CJS, GLOB_E2E, GLOB_IGNORES, GLOB_JS, GLOB_JSX, GLOB_NEXTJS, GLOB_PLAYWRIGHT, GLOB_TESTS, GLOB_TS, GLOB_TSX, GLOB_TYPE_TESTS };
|
|
80
|
+
export { GLOB_ASTRO, GLOB_CJS, GLOB_E2E, GLOB_IGNORES, GLOB_JS, GLOB_JSX, GLOB_NEXTJS, GLOB_NEXTJS_ENV, GLOB_PLAYWRIGHT, GLOB_TESTS, GLOB_TS, GLOB_TSX, GLOB_TYPE_TESTS };
|
package/dist/index.mjs
CHANGED
|
@@ -557,7 +557,7 @@ const defineConfig = async ({ astro = false, autoDetect = true, gitignore = fals
|
|
|
557
557
|
];
|
|
558
558
|
const featureConfigs = await Promise.all([
|
|
559
559
|
isTypescriptEnabled && unwrap(import("./typescript-BDNbtOD5.mjs"), typescript),
|
|
560
|
-
isReactEnabled && unwrap(import("./react-
|
|
560
|
+
isReactEnabled && unwrap(import("./react-CWFVE51B.mjs"), react),
|
|
561
561
|
isTanstackQueryEnabled && unwrap(import("./tanstack-query-ntNKBb-Z.mjs"), tanstackQuery),
|
|
562
562
|
isAstroEnabled && unwrap(import("./astro-B0kgVZlh.mjs"), astro),
|
|
563
563
|
isJestEnabled && unwrap(import("./jest-W70UkOeC.mjs"), jest),
|
|
@@ -565,7 +565,7 @@ const defineConfig = async ({ astro = false, autoDetect = true, gitignore = fals
|
|
|
565
565
|
isTestingLibraryEnabled && unwrap(import("./testing-library-B1I63Phd.mjs"), testingLibrary),
|
|
566
566
|
isPlaywrightEnabled && unwrap(import("./playwright-hse_Mk2B.mjs"), playwright),
|
|
567
567
|
isStorybookEnabled && unwrap(import("./storybook-Cmw5qksj.mjs"), storybook),
|
|
568
|
-
isNextjsEnabled && unwrap(import("./nextjs-
|
|
568
|
+
isNextjsEnabled && unwrap(import("./nextjs-Dq5nQ9ib.mjs"), nextjs)
|
|
569
569
|
]);
|
|
570
570
|
return [
|
|
571
571
|
...gitignore ? [gitignoreConfig({ strict: false })] : [],
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { GLOB_NEXTJS } from "./globs.mjs";
|
|
1
|
+
import { GLOB_NEXTJS, GLOB_NEXTJS_ENV } from "./globs.mjs";
|
|
2
2
|
import { n as extractOptions, t as unwrapDefault } from "./interop-default-BDN5nH8B.mjs";
|
|
3
3
|
import { t as upwarn } from "./upwarn-Bq0SLcj_.mjs";
|
|
4
4
|
//#region src/rules/nextjs.ts
|
|
@@ -18,6 +18,9 @@ async function nextjsConfig(options) {
|
|
|
18
18
|
name: "jimmy.codes/nextjs",
|
|
19
19
|
plugins: { "@next/next": nextjsPlugin },
|
|
20
20
|
rules: await nextjsRules(extractedOptions)
|
|
21
|
+
}, {
|
|
22
|
+
files: GLOB_NEXTJS_ENV,
|
|
23
|
+
rules: { "import-x/extensions": "off" }
|
|
21
24
|
}];
|
|
22
25
|
}
|
|
23
26
|
//#endregion
|
|
@@ -5,6 +5,7 @@ import { t as upwarn } from "./upwarn-Bq0SLcj_.mjs";
|
|
|
5
5
|
import globals from "globals";
|
|
6
6
|
//#region src/rules/react.ts
|
|
7
7
|
const nextAllowedExportNames = [
|
|
8
|
+
"experimental_ppr",
|
|
8
9
|
"dynamic",
|
|
9
10
|
"dynamicParams",
|
|
10
11
|
"revalidate",
|
|
@@ -12,12 +13,16 @@ const nextAllowedExportNames = [
|
|
|
12
13
|
"runtime",
|
|
13
14
|
"preferredRegion",
|
|
14
15
|
"maxDuration",
|
|
15
|
-
"config",
|
|
16
|
-
"generateStaticParams",
|
|
17
16
|
"metadata",
|
|
18
17
|
"generateMetadata",
|
|
19
18
|
"viewport",
|
|
20
|
-
"generateViewport"
|
|
19
|
+
"generateViewport",
|
|
20
|
+
"generateImageMetadata",
|
|
21
|
+
"generateSitemaps",
|
|
22
|
+
"generateStaticParams",
|
|
23
|
+
"alt",
|
|
24
|
+
"size",
|
|
25
|
+
"contentType"
|
|
21
26
|
];
|
|
22
27
|
const reactRules = async (options) => {
|
|
23
28
|
const [{ configs: reactConfigs }, { flatConfigs: jsxA11yConfigs }, { configs: reactDomConfigs }, { configs: reactHooksExtraConfigs }, { configs: reactWebApiConfigs }, { configs: reactNamingConventionConfigs }, { configs: reactRscConfigs }] = await Promise.all([
|