Skip to content

fix: use resolvable Ajv 2020 ESM import path#45

Merged
GsCommand merged 1 commit into
mainfrom
codex/fix-typescript-build-error-for-ajv-2020
May 18, 2026
Merged

fix: use resolvable Ajv 2020 ESM import path#45
GsCommand merged 1 commit into
mainfrom
codex/fix-typescript-build-error-for-ajv-2020

Conversation

@GsCommand
Copy link
Copy Markdown
Contributor

Motivation

  • Fix a TypeScript build error where the import ajv/dist/2020 is not resolvable in ESM environments by using the explicit ESM file path.

Description

  • Replace import Ajv2020 from "ajv/dist/2020"; with import Ajv2020 from "ajv/dist/2020.js"; in src/trust.ts and leave all validation logic unchanged; the only modified file is src/trust.ts.

Testing

  • Ran npm install, which failed with a 403 Forbidden error when fetching ajv, so dependencies were not installed.
  • Ran npm run build, which failed due to missing dependencies/types caused by the install failure (TypeScript errors for missing ajv, ajv-formats, and Node types).
  • Ran npm test, which failed because pretest runs npm run build, and the build failed for the same reason.

Codex Task

@GsCommand GsCommand merged commit 048e848 into main May 18, 2026
1 check failed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant