fix(admin-web/eslint): also ignore .pnpmfile.cjs at the dashboard level

The previous root-level eslint.config.js .cjs ignore (commit
1be38bef) had no effect on CI because 'pnpm -r exec eslint .' walks
into each workspace and invokes the LOCAL eslint config. admin-web
has its own dashboards/admin-web/eslint.config.mjs (extending
eslint-config-next), which did NOT ignore .cjs files. So the same
.pnpmfile.cjs require() errors kept failing run 64 and run 65 with
identical output.

Fix at the consumer (dashboard) level so 'pnpm -r exec eslint' sees
the ignore regardless of which workspace it runs from:

  globalIgnores([
    ...
    '.pnpmfile.cjs',
    '**/*.cjs',
  ])

Verified locally:
  cd dashboards/admin-web && pnpm lint  -> 0 errors

tracker-web has no .pnpmfile.cjs and no other .cjs configs, so its
eslint config does not need the same change yet — adding it would
be defensive but not required.
This commit is contained in:
saravanakumardb1 2026-05-23 17:06:56 -07:00
parent 1be38bef28
commit a4ee36b681

View File

@ -18,6 +18,12 @@ const eslintConfig = defineConfig([
"out/**",
"build/**",
"next-env.d.ts",
// .pnpmfile.cjs is a pnpm install hook (CommonJS by design).
// The TypeScript no-require-imports rule would otherwise flag
// every require() call in this file. eslint-config-next does NOT
// ignore .cjs by default.
".pnpmfile.cjs",
"**/*.cjs",
]),
]);