@dword-design/eslint-config 6.0.2 → 6.0.4
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/create/index.js +6 -4
- package/package.json +3 -4
package/dist/create/index.js
CHANGED
|
@@ -1,13 +1,14 @@
|
|
|
1
1
|
import pathLib from 'node:path';
|
|
2
2
|
import { fileURLToPath } from 'node:url';
|
|
3
3
|
import babelParser from '@babel/eslint-parser';
|
|
4
|
+
import { loadConfigSync } from '@dword-design/base';
|
|
4
5
|
import defu from '@dword-design/defu';
|
|
5
|
-
import { includeIgnoreFile } from '@eslint/compat';
|
|
6
6
|
import { FlatCompat } from '@eslint/eslintrc';
|
|
7
7
|
import js from '@eslint/js';
|
|
8
8
|
import confusingBrowserGlobals from 'confusing-browser-globals';
|
|
9
9
|
import packageName from 'depcheck-package-name';
|
|
10
10
|
import { defineConfig } from 'eslint/config';
|
|
11
|
+
import gitignore from 'eslint-config-flat-gitignore';
|
|
11
12
|
import importPlugin from 'eslint-plugin-import';
|
|
12
13
|
import eslintPluginJsonc from 'eslint-plugin-jsonc';
|
|
13
14
|
import pluginPlaywright from 'eslint-plugin-playwright';
|
|
@@ -15,7 +16,6 @@ import eslintPluginPrettierRecommended from 'eslint-plugin-prettier/recommended'
|
|
|
15
16
|
import pluginPromise from 'eslint-plugin-promise';
|
|
16
17
|
import eslintPluginUnicorn from 'eslint-plugin-unicorn';
|
|
17
18
|
import pluginVue from 'eslint-plugin-vue';
|
|
18
|
-
import fs from 'fs-extra';
|
|
19
19
|
import globals from 'globals';
|
|
20
20
|
import loadPkg from 'load-pkg';
|
|
21
21
|
import { compact, omit, without } from 'lodash-es';
|
|
@@ -23,7 +23,7 @@ import { sortOrder as packageJsonSortOrder } from 'sort-package-json';
|
|
|
23
23
|
import restrictedImports from "./restricted-imports.js";
|
|
24
24
|
export default () => {
|
|
25
25
|
const packageConfig = loadPkg.sync() || {};
|
|
26
|
-
const baseConfig = defu(
|
|
26
|
+
const baseConfig = defu(loadConfigSync(), {
|
|
27
27
|
testRunner: 'mocha'
|
|
28
28
|
});
|
|
29
29
|
const eslintRestrictedImports = restrictedImports.filter(importDef => importDef.alternative === undefined || importDef.alternative !== packageConfig.name).map(importDef => ({
|
|
@@ -37,7 +37,9 @@ export default () => {
|
|
|
37
37
|
const compat = new FlatCompat({
|
|
38
38
|
baseDirectory: __dirname
|
|
39
39
|
});
|
|
40
|
-
return defineConfig([
|
|
40
|
+
return defineConfig([gitignore({
|
|
41
|
+
strict: false
|
|
42
|
+
}), {
|
|
41
43
|
languageOptions: {
|
|
42
44
|
parser: babelParser,
|
|
43
45
|
parserOptions: {
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@dword-design/eslint-config",
|
|
3
|
-
"version": "6.0.
|
|
3
|
+
"version": "6.0.4",
|
|
4
4
|
"repository": "dword-design/eslint-config",
|
|
5
5
|
"funding": "https://github.com/sponsors/dword-design",
|
|
6
6
|
"license": "MIT",
|
|
@@ -23,14 +23,15 @@
|
|
|
23
23
|
},
|
|
24
24
|
"dependencies": {
|
|
25
25
|
"@babel/eslint-parser": "7.27.1",
|
|
26
|
+
"@dword-design/base": "^12.0.5",
|
|
26
27
|
"@dword-design/defu": "^1.0.0",
|
|
27
28
|
"@dword-design/eslint-plugin-import-alias": "^5.1.2",
|
|
28
|
-
"@eslint/compat": "^1.2.9",
|
|
29
29
|
"@eslint/eslintrc": "^3.3.1",
|
|
30
30
|
"@eslint/js": "^9.27.0",
|
|
31
31
|
"confusing-browser-globals": "^1.0.11",
|
|
32
32
|
"depcheck-package-name": "^3.0.1",
|
|
33
33
|
"eslint": "^9.27.0",
|
|
34
|
+
"eslint-config-flat-gitignore": "^2.1.0",
|
|
34
35
|
"eslint-config-prettier": "^10.1.5",
|
|
35
36
|
"eslint-import-resolver-babel-module": "^5.3.2",
|
|
36
37
|
"eslint-import-resolver-exports": "1.0.0-beta.5",
|
|
@@ -44,7 +45,6 @@
|
|
|
44
45
|
"eslint-plugin-sort-keys-fix": "^1.1.2",
|
|
45
46
|
"eslint-plugin-unicorn": "npm:@dword-design/eslint-plugin-unicorn@^0.0.1",
|
|
46
47
|
"eslint-plugin-vue": "^10.1.0",
|
|
47
|
-
"fs-extra": "^11.3.0",
|
|
48
48
|
"globals": "^16.1.0",
|
|
49
49
|
"load-pkg": "^4.0.0",
|
|
50
50
|
"lodash-es": "^4.17.21",
|
|
@@ -52,7 +52,6 @@
|
|
|
52
52
|
"sort-package-json": "^3.2.1"
|
|
53
53
|
},
|
|
54
54
|
"devDependencies": {
|
|
55
|
-
"@dword-design/base": "^12.0.1",
|
|
56
55
|
"@dword-design/functions": "^6.0.2",
|
|
57
56
|
"@playwright/test": "^1.52.0",
|
|
58
57
|
"execa": "^9.5.3",
|