diff --git a/src/lib/agents/registry.ts b/src/lib/agents/registry.ts index 97841a5..cbf706b 100644 --- a/src/lib/agents/registry.ts +++ b/src/lib/agents/registry.ts @@ -29,11 +29,15 @@ import { normalizeAgent } from './agentConfig'; * disabled list and nothing else, so it can only ever narrow a page. */ -/* `import.meta.glob` is a Vite build-time API. `tsc` models only the standard - `ImportMeta`, so it reports this as a missing property — a false positive - rather than a defect. Suppressed rather than cast: a cast would assert a type - nothing here can verify, and this file is the one place the glob appears. */ -// @ts-ignore -- Vite build-time API, absent from the standard ImportMeta type +/* `import.meta.glob` is a Vite build-time API, and it used to need a + `@ts-ignore` here: `tsc` models only the standard `ImportMeta` and reported + this as a missing property — a false positive rather than a defect. + + It is typed now. `tsconfig.json` sets `types: ["vite/client"]`, which + declares the Vite additions to `ImportMeta`, so the suppression had nothing + left to suppress. Removing it is the point rather than tidying: a directive + that no longer applies is one that would silently swallow a real error on + this line later. */ const FILES = import.meta.glob('/src/agents/**/*.md', { query: '?raw', import: 'default', eager: true }); /** diff --git a/src/vite-env.d.ts b/src/vite-env.d.ts index bd336d6..8077921 100644 --- a/src/vite-env.d.ts +++ b/src/vite-env.d.ts @@ -6,8 +6,9 @@ * * The reference above is what supplies `import.meta.env`, `import.meta.glob` * and the `?raw` module shape. Without it the two registries that discover - * agents and skills from the filesystem do not typecheck at all, and one of - * them carries a hand-written `@ts-ignore` saying so. + * agents and skills from the filesystem do not typecheck at all. One of them + * used to carry a hand-written `@ts-ignore` for exactly that reason; this + * reference is what made it redundant, and it has been removed. * * The interface below names the two variables this codebase reads. It does not * restrict `import.meta.env` to them — this declaration MERGES with Vite's,