Skip to content

Convert clients/js and clients/js-legacy to oxlint and oxfmt - #775

Merged
joncinque merged 1 commit into
solana-program:mainfrom
clankmaxxing-clod:convert-js-clients-to-oxlint-oxfmt
Aug 28, 2026
Merged

Convert clients/js and clients/js-legacy to oxlint and oxfmt#775
joncinque merged 1 commit into
solana-program:mainfrom
clankmaxxing-clod:convert-js-clients-to-oxlint-oxfmt

Conversation

@clankmaxxing-clod

Copy link
Copy Markdown
Contributor

Replaces ESLint + Prettier with oxlint and oxfmt for both JS client packages (clients/js and clients/js-legacy), mirroring solana-program/token-group#115 and the follow-ups in token-metadata, libraries, memo, and record.

Changes (applied identically to clients/js and clients/js-legacy)

  • package.json: dropped eslint, prettier, @typescript-eslint/eslint-plugin, eslint-config-prettier, eslint-plugin-prettier, and @solana/prettier-config-solana; added oxlint and oxfmt. Scripts now run the Oxc tools:
    • lintoxlint --max-warnings 0
    • lint:fixoxlint --fix
    • formatoxfmt --check .
    • format:fixoxfmt --write .
  • .oxlintrc.json (new) mirrors the old .eslintrc.cjs (@typescript-eslint/recommended): correctness category as errors, with ban-ts-comment / no-explicit-any / explicit-function-return-type / explicit-module-boundary-types disabled to match the previous rules.
  • .oxfmtrc.json (new) migrated from .prettierrc.cjs via oxfmt --migrate=prettier (single quotes, trailingComma: all, printWidth 100, endOfLine: lf, semicolons).
  • Removed .eslintrc.cjs, .eslintignore, and .prettierrc.cjs.
  • Updated the root pnpm-lock.yaml.

Notes

  • CI invokes pnpm lint / pnpm format per package through the repo Makefile, so no workflow files needed changing.
  • Existing source in both packages is already oxfmt-clean and oxlint-clean — no source reformatting in this PR.

Verification

For both packages: pnpm install, pnpm lint, pnpm format, and pnpm build all succeed; clients/js pnpm test (tsc) passes. A root pnpm install --frozen-lockfile succeeds against the updated lockfile. (The clients/js-legacy ava/litesvm suite needs the on-chain program .so built via cargo build-sbf — not run in this environment; it is unaffected by the tooling change.)

🤖 Generated with Claude Code

Replaces ESLint + Prettier with oxlint and oxfmt for both the
clients/js and clients/js-legacy packages.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
@joncinque

Copy link
Copy Markdown
Contributor

Audit failure was fixed with #776, landing on red

@joncinque
joncinque merged commit 32458df into solana-program:main Aug 28, 2026
23 of 24 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants