@ntnyq/eslint-config 3.3.0 → 3.3.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/README.md +2 -0
- package/dist/index.cjs +28 -0
- package/dist/index.d.cts +5605 -3818
- package/dist/index.d.ts +5605 -3818
- package/dist/index.js +42 -16
- package/package.json +8 -7
package/README.md
CHANGED
|
@@ -123,6 +123,8 @@ export interface ConfigOptions extends ConfigOptionsInternal {
|
|
|
123
123
|
|
|
124
124
|
javascript?: ConfigJavaScriptOptions
|
|
125
125
|
|
|
126
|
+
stylistic?: boolean | ConfigStylisticOptions
|
|
127
|
+
|
|
126
128
|
typescript?: boolean | ConfigTypeScriptOptions
|
|
127
129
|
|
|
128
130
|
unicorn?: boolean | ConfigUnicornOptions
|
package/dist/index.cjs
CHANGED
|
@@ -108,6 +108,7 @@ __export(src_exports, {
|
|
|
108
108
|
pluginPerfectionist: () => import_eslint_plugin_perfectionist.default,
|
|
109
109
|
pluginPrettier: () => import_eslint_plugin_prettier.default,
|
|
110
110
|
pluginRegexp: () => pluginRegexp,
|
|
111
|
+
pluginStylistic: () => import_eslint_plugin3.default,
|
|
111
112
|
pluginToml: () => import_eslint_plugin_toml.default,
|
|
112
113
|
pluginTypeScript: () => import_typescript_eslint3.plugin,
|
|
113
114
|
pluginUnicorn: () => import_eslint_plugin_unicorn.default,
|
|
@@ -123,6 +124,7 @@ __export(src_exports, {
|
|
|
123
124
|
resolveSubOptions: () => resolveSubOptions,
|
|
124
125
|
sort: () => sort,
|
|
125
126
|
specials: () => specials,
|
|
127
|
+
stylistic: () => stylistic,
|
|
126
128
|
test: () => test,
|
|
127
129
|
toArray: () => toArray,
|
|
128
130
|
toml: () => toml,
|
|
@@ -193,6 +195,7 @@ var import_eslint_plugin2 = __toESM(require("@vitest/eslint-plugin"), 1);
|
|
|
193
195
|
var import_eslint_plugin_import_x = __toESM(require("eslint-plugin-import-x"), 1);
|
|
194
196
|
var import_eslint_plugin_unicorn = __toESM(require("eslint-plugin-unicorn"), 1);
|
|
195
197
|
var import_eslint_plugin_prettier = __toESM(require("eslint-plugin-prettier"), 1);
|
|
198
|
+
var import_eslint_plugin3 = __toESM(require("@stylistic/eslint-plugin"), 1);
|
|
196
199
|
var import_eslint_plugin_github_action = __toESM(require("eslint-plugin-github-action"), 1);
|
|
197
200
|
var import_eslint_plugin_perfectionist = __toESM(require("eslint-plugin-perfectionist"), 1);
|
|
198
201
|
var import_eslint_plugin_unused_imports = __toESM(require("eslint-plugin-unused-imports"), 1);
|
|
@@ -1835,6 +1838,22 @@ var prettier = (options = {}) => {
|
|
|
1835
1838
|
];
|
|
1836
1839
|
};
|
|
1837
1840
|
|
|
1841
|
+
// src/configs/stylistic.ts
|
|
1842
|
+
var stylistic = (options = {}) => [
|
|
1843
|
+
{
|
|
1844
|
+
name: "ntnyq/stylistic",
|
|
1845
|
+
plugins: {
|
|
1846
|
+
"@stylistic": import_eslint_plugin3.default
|
|
1847
|
+
},
|
|
1848
|
+
rules: {
|
|
1849
|
+
// Only rules are not conflicted with Prettier
|
|
1850
|
+
// Use stylistic config to provide type support
|
|
1851
|
+
// Overrides rules
|
|
1852
|
+
...options.overrides
|
|
1853
|
+
}
|
|
1854
|
+
}
|
|
1855
|
+
];
|
|
1856
|
+
|
|
1838
1857
|
// src/configs/gitignore.ts
|
|
1839
1858
|
var import_eslint_config_flat_gitignore = __toESM(require("eslint-config-flat-gitignore"), 1);
|
|
1840
1859
|
var gitignore = (options = {}) => {
|
|
@@ -2354,6 +2373,13 @@ function defineESLintConfig(options = {}, userConfigs = []) {
|
|
|
2354
2373
|
})
|
|
2355
2374
|
);
|
|
2356
2375
|
}
|
|
2376
|
+
if (options.stylistic ?? true) {
|
|
2377
|
+
configs2.push(
|
|
2378
|
+
...stylistic({
|
|
2379
|
+
overrides: getOverrides(options, "stylistic")
|
|
2380
|
+
})
|
|
2381
|
+
);
|
|
2382
|
+
}
|
|
2357
2383
|
if (options.githubAction ?? true) {
|
|
2358
2384
|
configs2.push(
|
|
2359
2385
|
...githubAction({
|
|
@@ -2455,6 +2481,7 @@ function defineESLintConfig(options = {}, userConfigs = []) {
|
|
|
2455
2481
|
pluginPerfectionist,
|
|
2456
2482
|
pluginPrettier,
|
|
2457
2483
|
pluginRegexp,
|
|
2484
|
+
pluginStylistic,
|
|
2458
2485
|
pluginToml,
|
|
2459
2486
|
pluginTypeScript,
|
|
2460
2487
|
pluginUnicorn,
|
|
@@ -2470,6 +2497,7 @@ function defineESLintConfig(options = {}, userConfigs = []) {
|
|
|
2470
2497
|
resolveSubOptions,
|
|
2471
2498
|
sort,
|
|
2472
2499
|
specials,
|
|
2500
|
+
stylistic,
|
|
2473
2501
|
test,
|
|
2474
2502
|
toArray,
|
|
2475
2503
|
toml,
|