Bug
src/index.ts:445 exports a hardcoded version string that has drifted far from the actual package version:
export const VERSION = '0.1.0'; // src/index.ts:445
package.json is currently at 1.6.2. Any caller relying on VERSION for runtime introspection (logging, telemetry, user-agent strings) gets a stale value.
Root cause
The constant was never wired to the build pipeline — it's a manual string that was last updated at initial setup.
Fix options
- Remove the export — if no internal or external caller uses it, delete it. Run
grep -r 'VERSION' src/ to check.
- Derive at build time — inject via
tsup / vite define or a codegen step that reads package.json before compilation.
Acceptance criteria
Found by
Codebase audit (automated) — src/index.ts:445
Bug
src/index.ts:445exports a hardcoded version string that has drifted far from the actual package version:package.jsonis currently at1.6.2. Any caller relying onVERSIONfor runtime introspection (logging, telemetry, user-agent strings) gets a stale value.Root cause
The constant was never wired to the build pipeline — it's a manual string that was last updated at initial setup.
Fix options
grep -r 'VERSION' src/to check.tsup/vitedefine or a codegen step that readspackage.jsonbefore compilation.Acceptance criteria
VERSIONmatchespackage.json#versionat publish time, or the export is removedFound by
Codebase audit (automated) —
src/index.ts:445