@aryaemami59/eslint-config 0.0.5 → 0.0.6

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.
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","names":[],"sources":["../src/disabledRules.ts","../src/globalIgnores.ts","../src/globals.ts","../src/shareableConfigs.ts","../src/utils.ts"],"mappings":";;;;;;;;;;;;;;cASa,aAAA;EAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAb;cCEa,aAAA;EAAA,SAoBc,OAAA;EAAA,SAAA,IAAA;AAAA;;;;;;;;;;ADtB3B;cEEa,aAAA;EAAA;;;;;;;;;;;;;;;;;;;;;;;;;cA8BA,OAAA;EAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;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AAA,CAAO,MAAA"}
package/dist/index.js CHANGED
@@ -1,297 +1,327 @@
1
- // src/disabledRules.ts
2
- var disabledRules = {
3
- "no-undef": [0, { typeof: false }],
4
- "@typescript-eslint/no-unused-vars": [
5
- 0,
6
- {
7
- args: "all",
8
- argsIgnorePattern: "^_",
9
- caughtErrors: "all",
10
- caughtErrorsIgnorePattern: "^_",
11
- destructuredArrayIgnorePattern: "^_",
12
- varsIgnorePattern: "^_",
13
- ignoreRestSiblings: true
14
- }
15
- ],
16
- "@typescript-eslint/ban-ts-comment": [
17
- 0,
18
- {
19
- "ts-expect-error": "allow-with-description",
20
- "ts-ignore": true,
21
- "ts-nocheck": true,
22
- "ts-check": false,
23
- minimumDescriptionLength: 3
24
- }
25
- ]
26
- };
27
-
28
- // src/external.ts
29
1
  import js from "@eslint/js";
30
2
  import prettierConfig from "eslint-config-prettier/flat";
3
+ import globalIdentifiers from "globals";
31
4
  import { config, configs, parser, plugin } from "typescript-eslint";
5
+ import { defineConfig } from "eslint/config";
6
+
7
+ //#region src/disabledRules.ts
8
+ /**
9
+ * An object comprised of ESLint rules to disable.
10
+ * These rules are disabled in {@linkcode flatESLintConfig}.
11
+ *
12
+ * @since 0.0.3
13
+ * @public
14
+ */
15
+ const disabledRules = {
16
+ "@typescript-eslint/ban-ts-comment": [0, {
17
+ minimumDescriptionLength: 3,
18
+ "ts-check": false,
19
+ "ts-expect-error": "allow-with-description",
20
+ "ts-ignore": true,
21
+ "ts-nocheck": true
22
+ }],
23
+ "@typescript-eslint/consistent-generic-constructors": [0],
24
+ "@typescript-eslint/no-unused-vars": [0, {
25
+ args: "after-used",
26
+ argsIgnorePattern: "^_",
27
+ caughtErrors: "all",
28
+ caughtErrorsIgnorePattern: "^_",
29
+ destructuredArrayIgnorePattern: "^_",
30
+ ignoreClassWithStaticInitBlock: false,
31
+ ignoreRestSiblings: false,
32
+ reportUsedIgnorePattern: false,
33
+ vars: "all",
34
+ varsIgnorePattern: "^_"
35
+ }],
36
+ "no-undef": [0, { typeof: false }]
37
+ };
32
38
 
33
- // src/packageName.ts
34
- var packageName = "@aryaemami59/eslint-config";
39
+ //#endregion
40
+ //#region src/external.ts
41
+ const { browser, node, nodeBuiltin, vitest } = globalIdentifiers;
35
42
 
36
- // src/globalIgnores.ts
37
- var globalIgnores = {
38
- name: `${packageName}/global-ignores`,
39
- ignores: [
40
- "**/dist/",
41
- "**/build/",
42
- "**/lib/",
43
- "**/coverage/",
44
- "**/__snapshots__/",
45
- "**/temp/",
46
- "**/.temp/",
47
- "**/.tmp/",
48
- "**/.yalc/",
49
- "**/.yarn/",
50
- "**/.docusaurus/",
51
- "**/.next/",
52
- "**/.expo/",
53
- "**/*.snap"
54
- ]
43
+ //#endregion
44
+ //#region package.json
45
+ var name = "@aryaemami59/eslint-config";
46
+
47
+ //#endregion
48
+ //#region src/packageJsonName.ts
49
+ /**
50
+ * This is used because if we import the package name from the
51
+ * `package.json` file, it will be bundled into the final output,
52
+ * which is not desired.
53
+ *
54
+ * @since 0.0.5
55
+ * @internal
56
+ */
57
+ const packageJsonName = name;
58
+
59
+ //#endregion
60
+ //#region src/globalIgnores.ts
61
+ /**
62
+ * An object representing
63
+ * {@link https://eslint.org/docs/latest/use/configure/ignore#ignoring-files | **global ignore patterns**}
64
+ * for ESLint configuration.
65
+ *
66
+ * @since 0.0.3
67
+ * @public
68
+ */
69
+ const globalIgnores = {
70
+ ignores: [
71
+ "**/__snapshots__/",
72
+ "**/.docusaurus/",
73
+ "**/.expo/",
74
+ "**/.next/",
75
+ "**/.playwright/",
76
+ "**/.temp/",
77
+ "**/.tmp/",
78
+ "**/.turbo/",
79
+ "**/.wrangler/",
80
+ "**/.yalc/",
81
+ "**/.yarn/",
82
+ "**/*.snap",
83
+ "**/build/",
84
+ "**/coverage/",
85
+ "**/dist/",
86
+ "**/temp/"
87
+ ],
88
+ name: `${packageJsonName}/global-ignores`
55
89
  };
56
90
 
57
- // src/globals.ts
58
- import globalIdentifiers from "globals";
59
- var { browser, node, nodeBuiltin, vitest } = globalIdentifiers;
60
- var vitestGlobals = {
61
- suite: "writable",
62
- test: "writable",
63
- chai: "writable",
64
- describe: "writable",
65
- it: "writable",
66
- expectTypeOf: "writable",
67
- assertType: "writable",
68
- expect: "writable",
69
- assert: "writable",
70
- vitest: "writable",
71
- vi: "writable",
72
- beforeAll: "writable",
73
- afterAll: "writable",
74
- beforeEach: "writable",
75
- afterEach: "writable",
76
- onTestFailed: "writable",
77
- onTestFinished: "writable"
91
+ //#endregion
92
+ //#region src/globals.ts
93
+ /**
94
+ * An object representing the
95
+ * {@link https://vitest.dev/config/#globals | globals} provided by
96
+ * {@link https://vitest.dev | **Vitest**} for use in testing.
97
+ *
98
+ * @since 0.0.3
99
+ * @public
100
+ */
101
+ const vitestGlobals = {
102
+ afterAll: "writable",
103
+ afterEach: "writable",
104
+ assert: "writable",
105
+ assertType: "writable",
106
+ beforeAll: "writable",
107
+ beforeEach: "writable",
108
+ chai: "writable",
109
+ describe: "writable",
110
+ expect: "writable",
111
+ expectTypeOf: "writable",
112
+ it: "writable",
113
+ onTestFailed: "writable",
114
+ onTestFinished: "writable",
115
+ suite: "writable",
116
+ test: "writable",
117
+ vi: "writable",
118
+ vitest: "writable"
78
119
  };
79
- var globals = /* @__PURE__ */ Object.assign(
80
- {
81
- ...browser,
82
- ...node,
83
- ...nodeBuiltin
84
- },
85
- {
86
- ...vitest,
87
- ...vitestGlobals
88
- }
89
- );
120
+ /**
121
+ * An object that specifies which global
122
+ * variables are available during linting.
123
+ *
124
+ * @since 0.0.3
125
+ * @public
126
+ */
127
+ const globals = /* @__PURE__ */ Object.assign({
128
+ ...browser,
129
+ ...node,
130
+ ...nodeBuiltin
131
+ }, {
132
+ ...vitest,
133
+ ...vitestGlobals
134
+ });
90
135
 
91
- // src/shareableConfigs.ts
92
- var flatESLintConfig = /* @__PURE__ */ config(
93
- // `ignores` must be first.
94
- // config with just `ignores` is the replacement for `.eslintignore`
95
- globalIgnores,
96
- {
97
- name: `${js.meta.name}/recommended`,
98
- ...js.configs.recommended
99
- },
100
- configs.recommended,
101
- configs.stylistic,
102
- {
103
- name: `${packageName}/defaults/overrides`,
104
- languageOptions: {
105
- globals,
106
- parserOptions: {
107
- ecmaVersion: "latest",
108
- projectService: true
109
- }
110
- },
111
- rules: {
112
- "@typescript-eslint/consistent-type-imports": [
113
- 2,
114
- {
115
- disallowTypeAnnotations: true,
116
- fixStyle: "separate-type-imports",
117
- prefer: "type-imports"
118
- }
119
- ],
120
- "@typescript-eslint/consistent-type-exports": [
121
- 2,
122
- { fixMixedExportsWithInlineTypeSpecifier: false }
123
- ],
124
- "@typescript-eslint/no-explicit-any": [
125
- 2,
126
- {
127
- fixToUnknown: false,
128
- ignoreRestArgs: false
129
- }
130
- ],
131
- "@typescript-eslint/no-empty-object-type": [
132
- 2,
133
- {
134
- allowInterfaces: "never",
135
- allowObjectTypes: "never"
136
- }
137
- ],
138
- "@typescript-eslint/no-restricted-types": [
139
- 2,
140
- {
141
- types: {
142
- "{}": {
143
- message: `
144
- - If you want to represent an empty object, use \`type EmptyObject = Record<string, never>\`.
145
- - If you want to represent an object literal, use either \`type AnyObject = Record<string, any>\` or \`object\`.
146
- - If you want to represent any non-nullish value, use \`type AnyNonNullishValue = NonNullable<unknown>\`.`,
147
- suggest: [
148
- "AnyNonNullishValue",
149
- "EmptyObject",
150
- "AnyObject",
151
- "object",
152
- "Record<string, never>",
153
- "Record<string, any>",
154
- "NonNullable<unknown>"
155
- ]
156
- }
157
- }
158
- }
159
- ],
160
- "@typescript-eslint/no-namespace": [
161
- 2,
162
- {
163
- allowDeclarations: false,
164
- allowDefinitionFiles: true
165
- }
166
- ],
167
- "@typescript-eslint/consistent-type-definitions": [2, "type"],
168
- "sort-imports": [
169
- 2,
170
- {
171
- allowSeparatedGroups: true,
172
- ignoreCase: false,
173
- ignoreDeclarationSort: true,
174
- ignoreMemberSort: false,
175
- memberSyntaxSortOrder: ["none", "all", "multiple", "single"]
176
- }
177
- ],
178
- "@typescript-eslint/unified-signatures": [
179
- 2,
180
- {
181
- ignoreDifferentlyNamedParameters: false,
182
- ignoreOverloadsWithDifferentJSDoc: false
183
- }
184
- ],
185
- "@typescript-eslint/no-unnecessary-type-parameters": [2],
186
- "@typescript-eslint/no-invalid-void-type": [
187
- 2,
188
- {
189
- allowAsThisParameter: false,
190
- allowInGenericTypeArguments: true
191
- }
192
- ],
193
- "@typescript-eslint/no-confusing-void-expression": [
194
- 2,
195
- {
196
- ignoreArrowShorthand: false,
197
- ignoreVoidOperator: false,
198
- ignoreVoidReturningFunctions: false
199
- }
200
- ],
201
- "@typescript-eslint/no-duplicate-type-constituents": [
202
- 2,
203
- {
204
- ignoreIntersections: false,
205
- ignoreUnions: false
206
- }
207
- ],
208
- "@typescript-eslint/require-await": [2],
209
- "@typescript-eslint/no-redundant-type-constituents": [2],
210
- "@typescript-eslint/no-unnecessary-type-arguments": [2],
211
- "@typescript-eslint/no-unnecessary-type-assertion": [
212
- 2,
213
- { typesToIgnore: [] }
214
- ],
215
- "@typescript-eslint/prefer-nullish-coalescing": [
216
- 2,
217
- {
218
- allowRuleToRunWithoutStrictNullChecksIKnowWhatIAmDoing: false,
219
- ignoreBooleanCoercion: false,
220
- ignoreConditionalTests: true,
221
- ignoreIfStatements: false,
222
- ignoreMixedLogicalExpressions: false,
223
- ignorePrimitives: {
224
- bigint: false,
225
- boolean: false,
226
- number: false,
227
- string: false
228
- },
229
- ignoreTernaryTests: false
230
- }
231
- ],
232
- "@typescript-eslint/no-inferrable-types": [
233
- 2,
234
- {
235
- ignoreParameters: false,
236
- ignoreProperties: false
237
- }
238
- ],
239
- "@typescript-eslint/no-require-imports": [
240
- 2,
241
- {
242
- allow: [],
243
- allowAsImport: true
244
- }
245
- ],
246
- "object-shorthand": [
247
- 2,
248
- "always",
249
- {
250
- avoidExplicitReturnArrows: true,
251
- avoidQuotes: true,
252
- ignoreConstructors: true,
253
- methodsIgnorePattern: ""
254
- }
255
- ],
256
- ...disabledRules
257
- },
258
- linterOptions: {
259
- reportUnusedDisableDirectives: 2
260
- }
261
- },
262
- {
263
- name: `${packageName}/commonjs-files`,
264
- files: ["**/*.cjs"],
265
- languageOptions: {
266
- sourceType: "commonjs"
267
- },
268
- rules: {
269
- "@typescript-eslint/no-require-imports": [
270
- 0,
271
- {
272
- allow: [],
273
- allowAsImport: false
274
- }
275
- ]
276
- }
277
- },
278
- prettierConfig
279
- );
136
+ //#endregion
137
+ //#region src/shareableConfigs.ts
138
+ /**
139
+ * Flat ESLint configuration tailored for projects using TypeScript.
140
+ *
141
+ * @example
142
+ * <caption>#### __ECMAScript Modules (ESM) usage inside a file like `eslint.config.mts` or `eslint.config.mjs`__</caption>
143
+ *
144
+ * ```ts
145
+ * import { flatESLintConfig } from '@aryaemami59/eslint-config'
146
+ *
147
+ * export default flatESLintConfig
148
+ * ```
149
+ *
150
+ * @example
151
+ * <caption>#### __CommonJS (CJS) usage inside a file like `eslint.config.cts` or `eslint.config.cjs` (using `require`)__</caption>
152
+ *
153
+ * ```ts
154
+ * const { flatESLintConfig } = require('@aryaemami59/eslint-config')
155
+ *
156
+ * module.exports = flatESLintConfig
157
+ * ```
158
+ *
159
+ * @example
160
+ * <caption>#### __CommonJS (CJS) usage inside a file like `eslint.config.cjs` or `eslint.config.cts` (using dynamic import)__</caption>
161
+ *
162
+ * ```ts
163
+ * module.exports = (async () =>
164
+ * (await import('@aryaemami59/eslint-config')).flatESLintConfig)()
165
+ * ```
166
+ *
167
+ * @example
168
+ * <caption>#### __CommonJS (CJS) usage inside a file like `eslint.config.cts` (using import and export assignment)__</caption>
169
+ *
170
+ * ```ts
171
+ * import eslintConfigModule = require('@aryaemami59/eslint-config')
172
+ * import flatESLintConfig = eslintConfigModule.flatESLintConfig
173
+ *
174
+ * export = flatESLintConfig
175
+ * ```
176
+ *
177
+ * @since 0.0.3
178
+ * @public
179
+ */
180
+ const flatESLintConfig = [
181
+ globalIgnores,
182
+ {
183
+ name: `${js.meta.name}/recommended`,
184
+ ...js.configs.recommended
185
+ },
186
+ {
187
+ languageOptions: {
188
+ globals,
189
+ parserOptions: {
190
+ ecmaVersion: "latest",
191
+ projectService: true
192
+ }
193
+ },
194
+ linterOptions: {
195
+ reportUnusedDisableDirectives: 2,
196
+ reportUnusedInlineConfigs: 2
197
+ },
198
+ name: `${packageJsonName}/defaults/overrides`,
199
+ rules: {
200
+ "object-shorthand": [
201
+ 2,
202
+ "always",
203
+ {
204
+ avoidExplicitReturnArrows: true,
205
+ avoidQuotes: true,
206
+ ignoreConstructors: true,
207
+ methodsIgnorePattern: ""
208
+ }
209
+ ],
210
+ "sort-imports": [2, {
211
+ allowSeparatedGroups: true,
212
+ ignoreCase: false,
213
+ ignoreDeclarationSort: true,
214
+ ignoreMemberSort: false,
215
+ memberSyntaxSortOrder: [
216
+ "none",
217
+ "all",
218
+ "multiple",
219
+ "single"
220
+ ]
221
+ }],
222
+ ...disabledRules
223
+ }
224
+ },
225
+ {
226
+ files: ["**/*.cjs"],
227
+ languageOptions: { sourceType: "commonjs" },
228
+ name: `${packageJsonName}/commonjs-files`,
229
+ rules: { "@typescript-eslint/no-require-imports": [0, {
230
+ allow: [],
231
+ allowAsImport: false
232
+ }] }
233
+ },
234
+ prettierConfig
235
+ ];
280
236
 
281
- // src/utils.ts
282
- var createESLintConfig = (additionalOverrides = []) => /* @__PURE__ */ config(...flatESLintConfig, ...additionalOverrides);
283
- export {
284
- config,
285
- configs,
286
- createESLintConfig,
287
- disabledRules,
288
- flatESLintConfig,
289
- globalIgnores,
290
- globals,
291
- js,
292
- parser,
293
- plugin,
294
- prettierConfig,
295
- vitestGlobals
296
- };
237
+ //#endregion
238
+ //#region src/utils.ts
239
+ /**
240
+ * A function that returns {@linkcode flatESLintConfig}
241
+ * along with optional additional overrides.
242
+ * It's made mainly to provide intellisense and eliminate
243
+ * the need for manual type annotations using JSDoc comments.
244
+ *
245
+ * @param [additionalOverrides=[]] - **Optional** additional overrides to apply to the configuration.
246
+ * @returns An augmented version of the default {@linkcode flatESLintConfig}, incorporating any provided overrides.
247
+ *
248
+ * @example
249
+ * <caption>#### __ECMAScript Modules (ESM) usage inside a file like `eslint.config.mts` or `eslint.config.mjs`__</caption>
250
+ *
251
+ * ```ts
252
+ * import { createESLintConfig } from '@aryaemami59/eslint-config'
253
+ *
254
+ * export default createESLintConfig([
255
+ * {
256
+ * rules: {
257
+ * 'no-console': [0],
258
+ * },
259
+ * },
260
+ * {
261
+ * // ...Other additional overrides
262
+ * },
263
+ * ])
264
+ * ```
265
+ *
266
+ * @example
267
+ * <caption>#### __CommonJS (CJS) usage inside a file like `eslint.config.cts` or `eslint.config.cjs` (using `require`)__</caption>
268
+ *
269
+ * ```ts
270
+ * const { createESLintConfig } = require('@aryaemami59/eslint-config')
271
+ *
272
+ * module.exports = createESLintConfig([
273
+ * {
274
+ * rules: {
275
+ * 'no-console': [0],
276
+ * },
277
+ * },
278
+ * {
279
+ * // ...Other additional overrides
280
+ * },
281
+ * ])
282
+ * ```
283
+ *
284
+ * @example
285
+ * <caption>#### __CommonJS (CJS) usage inside a file like `eslint.config.cts` or `eslint.config.cjs` (using dynamic import)__</caption>
286
+ *
287
+ * ```ts
288
+ * module.exports = (async () =>
289
+ * (await import('@aryaemami59/eslint-config')).createESLintConfig([
290
+ * {
291
+ * rules: {
292
+ * 'no-console': [0],
293
+ * },
294
+ * },
295
+ * {
296
+ * // ...Other additional overrides
297
+ * },
298
+ * ]))()
299
+ * ```
300
+ *
301
+ * @example
302
+ * <caption>#### __CommonJS (CJS) usage inside a file like `eslint.config.cts` (using import and export assignment)__</caption>
303
+ *
304
+ * ```ts
305
+ * import eslintConfigModule = require('@aryaemami59/eslint-config')
306
+ * import createESLintConfig = eslintConfigModule.createESLintConfig
307
+ *
308
+ * export = createESLintConfig([
309
+ * {
310
+ * rules: {
311
+ * 'no-console': [0],
312
+ * },
313
+ * },
314
+ * {
315
+ * // ...Other additional overrides
316
+ * },
317
+ * ])
318
+ * ```
319
+ *
320
+ * @since 0.0.3
321
+ * @public
322
+ */
323
+ const createESLintConfig = (additionalOverrides = []) => /* @__PURE__ */ defineConfig(...flatESLintConfig, ...additionalOverrides);
324
+
325
+ //#endregion
326
+ export { config, configs, createESLintConfig, disabledRules, flatESLintConfig, globalIgnores, globals, js, parser, plugin, prettierConfig, vitestGlobals };
297
327
  //# sourceMappingURL=index.js.map