@mkaradeniz/eslint-config 4.0.8 → 4.0.9

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.
Files changed (2) hide show
  1. package/base.mjs +6 -1
  2. package/package.json +1 -1
package/base.mjs CHANGED
@@ -1,3 +1,4 @@
1
+ import { dirname } from 'node:path';
1
2
  import { fileURLToPath } from 'node:url';
2
3
  import eslintPluginComments from '@eslint-community/eslint-plugin-eslint-comments';
3
4
  import { includeIgnoreFile } from '@eslint/compat';
@@ -23,6 +24,10 @@ try {
23
24
  // Silently continue without .gitignore
24
25
  }
25
26
 
27
+ // Get the directory of the ESLint config file for proper tsconfig resolution
28
+ const __filename = fileURLToPath(import.meta.url);
29
+ const __dirname = dirname(__filename);
30
+
26
31
  export const baseConfig = [
27
32
  { ...baseRules },
28
33
  {
@@ -53,7 +58,7 @@ export const baseConfig = [
53
58
  parser: tseslint.parser,
54
59
  parserOptions: {
55
60
  project: true,
56
- tsconfigRootDir: process.cwd(),
61
+ tsconfigRootDir: __dirname,
57
62
  },
58
63
  sourceType: 'module',
59
64
  },
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@mkaradeniz/eslint-config",
3
- "version": "4.0.8",
3
+ "version": "4.0.9",
4
4
  "private": false,
5
5
  "files": [
6
6
  "base.mjs",