@adbayb/stack 2.40.0-next-ae97ae3 → 2.40.0-next-4118432

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.
@@ -7,6 +7,7 @@ const JAVASCRIPT_EXTENSIONS = ["js", "jsx", "cjs", "mjs", "mjsx"];
7
7
  const TYPESCRIPT_EXTENSIONS = ["ts", "tsx", "cts", "mts", "mtsx"];
8
8
  const JAVASCRIPT_LIKE_EXTENSIONS = [...JAVASCRIPT_EXTENSIONS, ...TYPESCRIPT_EXTENSIONS];
9
9
  const JAVASCRIPT_LIKE_EXTENSIONS_AS_STRING = JAVASCRIPT_LIKE_EXTENSIONS.join(",");
10
+ const JAVASCRIPT_LIKE_FILES = [`**/*.{${JAVASCRIPT_LIKE_EXTENSIONS_AS_STRING}}`];
10
11
 
11
12
  const TEST_LIKE_FILES = [
12
13
  `**/{test,test-d}.{${JAVASCRIPT_LIKE_EXTENSIONS_AS_STRING}}`,
@@ -32,6 +33,21 @@ const config = defineConfig({
32
33
  typeCheck: true,
33
34
  },
34
35
  overrides: [
36
+ {
37
+ files: ["**/*.d.ts"],
38
+ rules: {
39
+ "unicorn/require-module-specifiers": "off",
40
+ },
41
+ },
42
+ {
43
+ files: JAVASCRIPT_LIKE_FILES,
44
+ rules: {
45
+ "typescript/no-unsafe-assignment": "off",
46
+ "typescript/no-unsafe-call": "off",
47
+ "typescript/no-unsafe-member-access": "off",
48
+ "typescript/no-unsafe-return": "off",
49
+ },
50
+ },
35
51
  {
36
52
  files: TEST_LIKE_FILES,
37
53
  plugins: ["vitest"],
@@ -73,12 +89,6 @@ const config = defineConfig({
73
89
  "react/forbid-component-props": "off",
74
90
  },
75
91
  },
76
- {
77
- files: ["**/*.d.ts"],
78
- rules: {
79
- "unicorn/require-module-specifiers": "off",
80
- },
81
- },
82
92
  ],
83
93
  plugins: [
84
94
  "eslint",
@@ -89,7 +99,7 @@ const config = defineConfig({
89
99
  "oxc",
90
100
  "promise",
91
101
  "react",
92
- "react-perf",
102
+ // "react-perf", // is disabled because it flags patterns that are often harmless, its optimization rules don't align well with modern React performance guidance, it generates more noise than value, and we prefer profiling-driven optimizations over enforced manual optimizations.
93
103
  "typescript",
94
104
  "unicorn",
95
105
  ],
@@ -260,6 +270,7 @@ const config = defineConfig({
260
270
  "react/jsx-no-literals": "off",
261
271
  "react/jsx-props-no-spreading": "off",
262
272
  "react/no-multi-comp": "off",
273
+ "react/only-export-components": ["error", { allowConstantExport: true }],
263
274
  "react/prefer-function-component": [
264
275
  "error",
265
276
  { allowErrorBoundary: true, allowJsxUtilityClass: true },
@@ -280,7 +291,6 @@ const config = defineConfig({
280
291
  "unicorn/import-style": "off",
281
292
  "unicorn/no-array-for-each": "off",
282
293
  "unicorn/no-array-reduce": "off",
283
- "unicorn/no-typeof-undefined": ["error", { checkGlobalVariables: true }],
284
294
  "unicorn/no-useless-undefined": "off",
285
295
  },
286
296
  });
@@ -20,6 +20,50 @@ declare const config: {
20
20
  typeCheck: true;
21
21
  };
22
22
  overrides: ({
23
+ files: string[];
24
+ rules: {
25
+ "unicorn/require-module-specifiers": "off";
26
+ "typescript/no-unsafe-assignment"?: never;
27
+ "typescript/no-unsafe-call"?: never;
28
+ "typescript/no-unsafe-member-access"?: never;
29
+ "typescript/no-unsafe-return"?: never;
30
+ "vitest/consistent-test-it"?: never;
31
+ "vitest/no-hooks"?: never;
32
+ "vitest/no-importing-vitest-globals"?: never;
33
+ "vitest/prefer-to-be-falsy"?: never;
34
+ "vitest/prefer-to-be-truthy"?: never;
35
+ "vitest/require-mock-type-parameters"?: never;
36
+ "vitest/require-test-timeout"?: never;
37
+ "vitest/valid-title"?: never;
38
+ "e18e/prefer-static-regex"?: never;
39
+ "import/no-anonymous-default-export"?: never;
40
+ "import/no-default-export"?: never;
41
+ "react/forbid-component-props"?: never;
42
+ };
43
+ plugins?: never;
44
+ } | {
45
+ files: string[];
46
+ rules: {
47
+ "typescript/no-unsafe-assignment": "off";
48
+ "typescript/no-unsafe-call": "off";
49
+ "typescript/no-unsafe-member-access": "off";
50
+ "typescript/no-unsafe-return": "off";
51
+ "unicorn/require-module-specifiers"?: never;
52
+ "vitest/consistent-test-it"?: never;
53
+ "vitest/no-hooks"?: never;
54
+ "vitest/no-importing-vitest-globals"?: never;
55
+ "vitest/prefer-to-be-falsy"?: never;
56
+ "vitest/prefer-to-be-truthy"?: never;
57
+ "vitest/require-mock-type-parameters"?: never;
58
+ "vitest/require-test-timeout"?: never;
59
+ "vitest/valid-title"?: never;
60
+ "e18e/prefer-static-regex"?: never;
61
+ "import/no-anonymous-default-export"?: never;
62
+ "import/no-default-export"?: never;
63
+ "react/forbid-component-props"?: never;
64
+ };
65
+ plugins?: never;
66
+ } | {
23
67
  files: string[];
24
68
  plugins: "vitest"[];
25
69
  rules: {
@@ -39,11 +83,15 @@ declare const config: {
39
83
  test: string[];
40
84
  };
41
85
  }];
86
+ "unicorn/require-module-specifiers"?: never;
87
+ "typescript/no-unsafe-assignment"?: never;
88
+ "typescript/no-unsafe-call"?: never;
89
+ "typescript/no-unsafe-member-access"?: never;
90
+ "typescript/no-unsafe-return"?: never;
42
91
  "e18e/prefer-static-regex"?: never;
43
92
  "import/no-anonymous-default-export"?: never;
44
93
  "import/no-default-export"?: never;
45
94
  "react/forbid-component-props"?: never;
46
- "unicorn/require-module-specifiers"?: never;
47
95
  };
48
96
  } | {
49
97
  files: string[];
@@ -52,21 +100,11 @@ declare const config: {
52
100
  "import/no-anonymous-default-export": "off";
53
101
  "import/no-default-export": "off";
54
102
  "react/forbid-component-props": "off";
55
- "vitest/consistent-test-it"?: never;
56
- "vitest/no-hooks"?: never;
57
- "vitest/no-importing-vitest-globals"?: never;
58
- "vitest/prefer-to-be-falsy"?: never;
59
- "vitest/prefer-to-be-truthy"?: never;
60
- "vitest/require-mock-type-parameters"?: never;
61
- "vitest/require-test-timeout"?: never;
62
- "vitest/valid-title"?: never;
63
103
  "unicorn/require-module-specifiers"?: never;
64
- };
65
- plugins?: never;
66
- } | {
67
- files: string[];
68
- rules: {
69
- "unicorn/require-module-specifiers": "off";
104
+ "typescript/no-unsafe-assignment"?: never;
105
+ "typescript/no-unsafe-call"?: never;
106
+ "typescript/no-unsafe-member-access"?: never;
107
+ "typescript/no-unsafe-return"?: never;
70
108
  "vitest/consistent-test-it"?: never;
71
109
  "vitest/no-hooks"?: never;
72
110
  "vitest/no-importing-vitest-globals"?: never;
@@ -75,14 +113,10 @@ declare const config: {
75
113
  "vitest/require-mock-type-parameters"?: never;
76
114
  "vitest/require-test-timeout"?: never;
77
115
  "vitest/valid-title"?: never;
78
- "e18e/prefer-static-regex"?: never;
79
- "import/no-anonymous-default-export"?: never;
80
- "import/no-default-export"?: never;
81
- "react/forbid-component-props"?: never;
82
116
  };
83
117
  plugins?: never;
84
118
  })[];
85
- plugins: ("eslint" | "react" | "unicorn" | "typescript" | "oxc" | "import" | "jsdoc" | "jsx-a11y" | "react-perf" | "promise" | "node")[];
119
+ plugins: ("eslint" | "react" | "unicorn" | "typescript" | "oxc" | "import" | "jsdoc" | "jsx-a11y" | "promise" | "node")[];
86
120
  rules: {
87
121
  "@stylistic/jsx-pascal-case": "error";
88
122
  "@stylistic/jsx-self-closing-comp": "error";
@@ -193,6 +227,9 @@ declare const config: {
193
227
  "react/jsx-no-literals": "off";
194
228
  "react/jsx-props-no-spreading": "off";
195
229
  "react/no-multi-comp": "off";
230
+ "react/only-export-components": ["error", {
231
+ allowConstantExport: true;
232
+ }];
196
233
  "react/prefer-function-component": ["error", {
197
234
  allowErrorBoundary: true;
198
235
  allowJsxUtilityClass: true;
@@ -213,9 +250,6 @@ declare const config: {
213
250
  "unicorn/import-style": "off";
214
251
  "unicorn/no-array-for-each": "off";
215
252
  "unicorn/no-array-reduce": "off";
216
- "unicorn/no-typeof-undefined": ["error", {
217
- checkGlobalVariables: true;
218
- }];
219
253
  "unicorn/no-useless-undefined": "off";
220
254
  };
221
255
  };
@@ -18,6 +18,7 @@ const TYPESCRIPT_EXTENSIONS = [
18
18
  "mtsx"
19
19
  ];
20
20
  const JAVASCRIPT_LIKE_EXTENSIONS_AS_STRING = [...JAVASCRIPT_EXTENSIONS, ...TYPESCRIPT_EXTENSIONS].join(",");
21
+ const JAVASCRIPT_LIKE_FILES = [`**/*.{${JAVASCRIPT_LIKE_EXTENSIONS_AS_STRING}}`];
21
22
  const TEST_LIKE_FILES = [`**/{test,test-d}.{${JAVASCRIPT_LIKE_EXTENSIONS_AS_STRING}}`, `**/*.{test,test-d}.{${JAVASCRIPT_LIKE_EXTENSIONS_AS_STRING}}`];
22
23
  const config = defineConfig({
23
24
  categories: {
@@ -42,6 +43,19 @@ const config = defineConfig({
42
43
  typeCheck: true
43
44
  },
44
45
  overrides: [
46
+ {
47
+ files: ["**/*.d.ts"],
48
+ rules: { "unicorn/require-module-specifiers": "off" }
49
+ },
50
+ {
51
+ files: JAVASCRIPT_LIKE_FILES,
52
+ rules: {
53
+ "typescript/no-unsafe-assignment": "off",
54
+ "typescript/no-unsafe-call": "off",
55
+ "typescript/no-unsafe-member-access": "off",
56
+ "typescript/no-unsafe-return": "off"
57
+ }
58
+ },
45
59
  {
46
60
  files: TEST_LIKE_FILES,
47
61
  plugins: ["vitest"],
@@ -85,10 +99,6 @@ const config = defineConfig({
85
99
  "import/no-default-export": "off",
86
100
  "react/forbid-component-props": "off"
87
101
  }
88
- },
89
- {
90
- files: ["**/*.d.ts"],
91
- rules: { "unicorn/require-module-specifiers": "off" }
92
102
  }
93
103
  ],
94
104
  plugins: [
@@ -100,7 +110,6 @@ const config = defineConfig({
100
110
  "oxc",
101
111
  "promise",
102
112
  "react",
103
- "react-perf",
104
113
  "typescript",
105
114
  "unicorn"
106
115
  ],
@@ -271,6 +280,7 @@ const config = defineConfig({
271
280
  "react/jsx-no-literals": "off",
272
281
  "react/jsx-props-no-spreading": "off",
273
282
  "react/no-multi-comp": "off",
283
+ "react/only-export-components": ["error", { allowConstantExport: true }],
274
284
  "react/prefer-function-component": ["error", {
275
285
  allowErrorBoundary: true,
276
286
  allowJsxUtilityClass: true
@@ -291,7 +301,6 @@ const config = defineConfig({
291
301
  "unicorn/import-style": "off",
292
302
  "unicorn/no-array-for-each": "off",
293
303
  "unicorn/no-array-reduce": "off",
294
- "unicorn/no-typeof-undefined": ["error", { checkGlobalVariables: true }],
295
304
  "unicorn/no-useless-undefined": "off"
296
305
  }
297
306
  });
package/dist/index.js CHANGED
@@ -442,7 +442,7 @@ const PRESERVE_FILES = ["node_modules"];
442
442
 
443
443
  //#endregion
444
444
  //#region package.json
445
- var version = "2.40.0-next-ae97ae3";
445
+ var version = "2.40.0-next-4118432";
446
446
 
447
447
  //#endregion
448
448
  //#region src/commands/create.ts
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@adbayb/stack",
3
- "version": "2.40.0-next-ae97ae3",
3
+ "version": "2.40.0-next-4118432",
4
4
  "description": "My opinionated JavaScript-based toolchain",
5
5
  "keywords": [
6
6
  "development",