@kouts/eslint-config 1.3.6 → 1.3.8

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/index.cjs CHANGED
@@ -422,6 +422,19 @@ const vue = (options) => {
422
422
  return config;
423
423
  };
424
424
 
425
+ const pluginImportTypescript = Object.keys(pluginImport.flatConfigs.typescript).reduce(
426
+ (acc, key) => ({
427
+ ...acc,
428
+ [key]: Object.keys(pluginImport.flatConfigs.typescript[key]).reduce(
429
+ (innerAcc, curr) => ({
430
+ ...innerAcc,
431
+ [curr.replace("import-x", "import")]: pluginImport.flatConfigs.typescript[key][curr]
432
+ }),
433
+ {}
434
+ )
435
+ }),
436
+ {}
437
+ );
425
438
  const config = (options) => {
426
439
  const opts = {
427
440
  noJsx: true,
@@ -478,6 +491,7 @@ const config = (options) => {
478
491
  plugins: {
479
492
  import: pluginImport
480
493
  },
494
+ ...opts.ts ? pluginImportTypescript : {},
481
495
  rules: {
482
496
  "import/export": "error",
483
497
  "import/first": "error",
package/dist/index.js CHANGED
@@ -421,6 +421,19 @@ const vue = (options) => {
421
421
  return config;
422
422
  };
423
423
 
424
+ const pluginImportTypescript = Object.keys(pluginImport.flatConfigs.typescript).reduce(
425
+ (acc, key) => ({
426
+ ...acc,
427
+ [key]: Object.keys(pluginImport.flatConfigs.typescript[key]).reduce(
428
+ (innerAcc, curr) => ({
429
+ ...innerAcc,
430
+ [curr.replace("import-x", "import")]: pluginImport.flatConfigs.typescript[key][curr]
431
+ }),
432
+ {}
433
+ )
434
+ }),
435
+ {}
436
+ );
424
437
  const config = (options) => {
425
438
  const opts = {
426
439
  noJsx: true,
@@ -477,6 +490,7 @@ const config = (options) => {
477
490
  plugins: {
478
491
  import: pluginImport
479
492
  },
493
+ ...opts.ts ? pluginImportTypescript : {},
480
494
  rules: {
481
495
  "import/export": "error",
482
496
  "import/first": "error",
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@kouts/eslint-config",
3
3
  "type": "module",
4
- "version": "1.3.6",
4
+ "version": "1.3.8",
5
5
  "packageManager": "pnpm@9.9.0",
6
6
  "engines": {
7
7
  "node": "^18.18.0 || ^20.9.0 || >=21.1.0"
@@ -75,7 +75,7 @@
75
75
  "eslint-plugin-import-x": "^4.1.1",
76
76
  "eslint-plugin-prettier": "^5.2.1",
77
77
  "eslint-plugin-simple-import-sort": "^12.1.1",
78
- "eslint-plugin-vue": "^9.27.0",
78
+ "eslint-plugin-vue": "^9.28.0",
79
79
  "neostandard": "^0.11.4",
80
80
  "prettier": "^3.3.3"
81
81
  },
@@ -84,10 +84,10 @@
84
84
  "@commitlint/config-conventional": "^19.4.1",
85
85
  "@semantic-release/changelog": "^6.0.3",
86
86
  "@semantic-release/git": "^10.0.1",
87
- "@types/node": "^22.5.1",
87
+ "@types/node": "^22.5.2",
88
88
  "eslint": "^9.9.1",
89
89
  "husky": "^9.1.5",
90
- "lint-staged": "^15.2.9",
90
+ "lint-staged": "^15.2.10",
91
91
  "pkgroll": "^2.4.2",
92
92
  "semantic-release": "^24.1.0",
93
93
  "typescript": "^5.5.4"