@eienjs/eslint-config 1.9.2 → 1.9.3
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/cli/constants_generated.mjs +6 -6
- package/dist/configs/adonisjs.mjs +2 -1
- package/dist/configs/formatters.mjs +1 -1
- package/dist/configs/ignores.d.mts +1 -1
- package/dist/configs/ignores.mjs +3 -2
- package/dist/configs/jsdoc.mjs +2 -0
- package/dist/configs/node.mjs +2 -0
- package/dist/factory.mjs +1 -1
- package/dist/index.d.mts +2 -2
- package/dist/package.mjs +1 -1
- package/dist/typegen.d.mts +226 -167
- package/dist/types.d.mts +2 -1
- package/package.json +41 -38
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
//#region src/cli/constants_generated.ts
|
|
2
2
|
const versionsMap = {
|
|
3
|
-
"@adonisjs/eslint-plugin": "^2.2.
|
|
4
|
-
"@nuxt/eslint-plugin": "^1.
|
|
5
|
-
"astro-eslint-parser": "^1.
|
|
6
|
-
"eslint": "^9.39.
|
|
7
|
-
"eslint-plugin-astro": "^1.
|
|
8
|
-
"eslint-plugin-format": "^1.
|
|
3
|
+
"@adonisjs/eslint-plugin": "^2.2.2",
|
|
4
|
+
"@nuxt/eslint-plugin": "^1.15.1",
|
|
5
|
+
"astro-eslint-parser": "^1.3.0",
|
|
6
|
+
"eslint": "^9.39.3",
|
|
7
|
+
"eslint-plugin-astro": "^1.6.0",
|
|
8
|
+
"eslint-plugin-format": "^1.4.0",
|
|
9
9
|
"prettier-plugin-astro": "^0.14.1"
|
|
10
10
|
};
|
|
11
11
|
|
|
@@ -74,7 +74,8 @@ async function adonisjs(options = {}) {
|
|
|
74
74
|
name: "eienjs/adonisjs/bin-disables",
|
|
75
75
|
rules: {
|
|
76
76
|
...commonRulesSet,
|
|
77
|
-
"@typescript-eslint/no-misused-promises": "off"
|
|
77
|
+
"@typescript-eslint/no-misused-promises": "off",
|
|
78
|
+
"n/prefer-global/process": "off"
|
|
78
79
|
}
|
|
79
80
|
},
|
|
80
81
|
{
|
|
@@ -3,7 +3,7 @@ import { ensurePackages, interopDefault, isPackageInScope, parserPlain } from ".
|
|
|
3
3
|
import { StylisticConfigDefaults } from "./stylistic.mjs";
|
|
4
4
|
|
|
5
5
|
//#region src/configs/formatters.ts
|
|
6
|
-
function mergePrettierOptions(options, overrides
|
|
6
|
+
function mergePrettierOptions(options, overrides) {
|
|
7
7
|
return {
|
|
8
8
|
...options,
|
|
9
9
|
...overrides,
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { TypedFlatConfigItem } from "../types.mjs";
|
|
2
2
|
|
|
3
3
|
//#region src/configs/ignores.d.ts
|
|
4
|
-
declare function ignores(userIgnores?: string[] | ((originals: string[]) => string[])): TypedFlatConfigItem[];
|
|
4
|
+
declare function ignores(userIgnores?: string[] | ((originals: string[]) => string[]), ignoreTypescript?: boolean): TypedFlatConfigItem[];
|
|
5
5
|
//#endregion
|
|
6
6
|
export { ignores };
|
package/dist/configs/ignores.mjs
CHANGED
|
@@ -1,8 +1,9 @@
|
|
|
1
|
-
import { GLOB_EXCLUDE } from "../globs.mjs";
|
|
1
|
+
import { GLOB_EXCLUDE, GLOB_TS, GLOB_TSX } from "../globs.mjs";
|
|
2
2
|
|
|
3
3
|
//#region src/configs/ignores.ts
|
|
4
|
-
function ignores(userIgnores = []) {
|
|
4
|
+
function ignores(userIgnores = [], ignoreTypescript = false) {
|
|
5
5
|
let ignores = [...GLOB_EXCLUDE];
|
|
6
|
+
if (ignoreTypescript) ignores.push(GLOB_TS, GLOB_TSX);
|
|
6
7
|
ignores = typeof userIgnores === "function" ? userIgnores(ignores) : [...ignores, ...userIgnores];
|
|
7
8
|
return [{
|
|
8
9
|
ignores,
|
package/dist/configs/jsdoc.mjs
CHANGED
|
@@ -1,9 +1,11 @@
|
|
|
1
|
+
import { GLOB_SRC } from "../globs.mjs";
|
|
1
2
|
import { interopDefault } from "../utils.mjs";
|
|
2
3
|
|
|
3
4
|
//#region src/configs/jsdoc.ts
|
|
4
5
|
async function jsdoc(options = {}) {
|
|
5
6
|
const { stylistic = true } = options;
|
|
6
7
|
return [{
|
|
8
|
+
files: [GLOB_SRC],
|
|
7
9
|
name: "eienjs/jsdoc/rules",
|
|
8
10
|
plugins: { jsdoc: await interopDefault(import("eslint-plugin-jsdoc")) },
|
|
9
11
|
rules: {
|
package/dist/configs/node.mjs
CHANGED
package/dist/factory.mjs
CHANGED
|
@@ -68,7 +68,7 @@ function eienjs(options = {}) {
|
|
|
68
68
|
...enableGitignore
|
|
69
69
|
})]));
|
|
70
70
|
const typescriptOptions = resolveSubOptions(options, "typescript");
|
|
71
|
-
configs.push(ignores(userIgnores), javascript({
|
|
71
|
+
configs.push(ignores(userIgnores, !enableTypeScript), javascript({
|
|
72
72
|
isInEditor,
|
|
73
73
|
overrides: getOverrides(options, "javascript")
|
|
74
74
|
}), comments(), command(), perfectionist());
|
package/dist/index.d.mts
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import { ConfigNames } from "./typegen.mjs";
|
|
1
|
+
import { ConfigNames, RuleOptions } from "./typegen.mjs";
|
|
2
2
|
import { Awaitable, OptionsAdonisJS, OptionsComponentExts, OptionsConfig, OptionsErasableSyntaxOnly, OptionsFiles, OptionsFormatters, OptionsHasTypeScript, OptionsIsInEditor, OptionsNuxt, OptionsOverrides, OptionsPnpm, OptionsRegExp, OptionsStylistic, OptionsTypeScriptParserOptions, OptionsTypeScriptWithTypes, OptionsTypescript, OptionsTypescriptWithErasableSyntaxOnly, OptionsVue, Rules, StylisticConfig, TypedFlatConfigItem } from "./types.mjs";
|
|
3
3
|
import { ResolvedOptions, defaultPluginRenaming, eienjs, getOverrides, resolveSubOptions } from "./factory.mjs";
|
|
4
4
|
import { CONFIG_PRESET_FULL_OFF, CONFIG_PRESET_FULL_ON } from "./config_presets.mjs";
|
|
5
5
|
import { GLOB_ALL_SRC, GLOB_ASTRO, GLOB_ASTRO_TS, GLOB_CSS, GLOB_EXCLUDE, GLOB_EXTS, GLOB_HTML, GLOB_JS, GLOB_JSON, GLOB_JSON5, GLOB_JSONC, GLOB_JSX, GLOB_LESS, GLOB_MARKDOWN, GLOB_MARKDOWN_CODE, GLOB_MARKDOWN_IN_MARKDOWN, GLOB_POSTCSS, GLOB_SCSS, GLOB_SRC, GLOB_SRC_EXT, GLOB_STYLE, GLOB_SVG, GLOB_TESTS, GLOB_TOML, GLOB_TS, GLOB_TSX, GLOB_VUE, GLOB_XML, GLOB_YAML } from "./globs.mjs";
|
|
6
6
|
import { combine, ensurePackages, interopDefault, isInEditorEnv, isInGitHooksOrLintStaged, isPackageInScope, parserPlain, toArray } from "./utils.mjs";
|
|
7
|
-
export { Awaitable, CONFIG_PRESET_FULL_OFF, CONFIG_PRESET_FULL_ON, ConfigNames, GLOB_ALL_SRC, GLOB_ASTRO, GLOB_ASTRO_TS, GLOB_CSS, GLOB_EXCLUDE, GLOB_EXTS, GLOB_HTML, GLOB_JS, GLOB_JSON, GLOB_JSON5, GLOB_JSONC, GLOB_JSX, GLOB_LESS, GLOB_MARKDOWN, GLOB_MARKDOWN_CODE, GLOB_MARKDOWN_IN_MARKDOWN, GLOB_POSTCSS, GLOB_SCSS, GLOB_SRC, GLOB_SRC_EXT, GLOB_STYLE, GLOB_SVG, GLOB_TESTS, GLOB_TOML, GLOB_TS, GLOB_TSX, GLOB_VUE, GLOB_XML, GLOB_YAML, OptionsAdonisJS, OptionsComponentExts, OptionsConfig, OptionsErasableSyntaxOnly, OptionsFiles, OptionsFormatters, OptionsHasTypeScript, OptionsIsInEditor, OptionsNuxt, OptionsOverrides, OptionsPnpm, OptionsRegExp, OptionsStylistic, OptionsTypeScriptParserOptions, OptionsTypeScriptWithTypes, OptionsTypescript, OptionsTypescriptWithErasableSyntaxOnly, OptionsVue, ResolvedOptions, Rules, StylisticConfig, TypedFlatConfigItem, combine, eienjs as default, defaultPluginRenaming, eienjs, ensurePackages, getOverrides, interopDefault, isInEditorEnv, isInGitHooksOrLintStaged, isPackageInScope, parserPlain, resolveSubOptions, toArray };
|
|
7
|
+
export { Awaitable, CONFIG_PRESET_FULL_OFF, CONFIG_PRESET_FULL_ON, ConfigNames, GLOB_ALL_SRC, GLOB_ASTRO, GLOB_ASTRO_TS, GLOB_CSS, GLOB_EXCLUDE, GLOB_EXTS, GLOB_HTML, GLOB_JS, GLOB_JSON, GLOB_JSON5, GLOB_JSONC, GLOB_JSX, GLOB_LESS, GLOB_MARKDOWN, GLOB_MARKDOWN_CODE, GLOB_MARKDOWN_IN_MARKDOWN, GLOB_POSTCSS, GLOB_SCSS, GLOB_SRC, GLOB_SRC_EXT, GLOB_STYLE, GLOB_SVG, GLOB_TESTS, GLOB_TOML, GLOB_TS, GLOB_TSX, GLOB_VUE, GLOB_XML, GLOB_YAML, OptionsAdonisJS, OptionsComponentExts, OptionsConfig, OptionsErasableSyntaxOnly, OptionsFiles, OptionsFormatters, OptionsHasTypeScript, OptionsIsInEditor, OptionsNuxt, OptionsOverrides, OptionsPnpm, OptionsRegExp, OptionsStylistic, OptionsTypeScriptParserOptions, OptionsTypeScriptWithTypes, OptionsTypescript, OptionsTypescriptWithErasableSyntaxOnly, OptionsVue, ResolvedOptions, RuleOptions, Rules, StylisticConfig, TypedFlatConfigItem, combine, eienjs as default, defaultPluginRenaming, eienjs, ensurePackages, getOverrides, interopDefault, isInEditorEnv, isInGitHooksOrLintStaged, isPackageInScope, parserPlain, resolveSubOptions, toArray };
|
package/dist/package.mjs
CHANGED