-
Notifications
You must be signed in to change notification settings - Fork 0
Description
Summary
Adopt Oxlint across the monorepo as a complementary JS/TS linter alongside existing tooling (Biome, ktlint, gofmt, buf, etc.), and integrate type-aware checks via tsgolint where supported. This should add new lint entrypoints without replacing current ones.
Context
- JS/TS linting today is Biome-centric (root
biome.json, workspace scripts callbunx biome checkorbiome lint). - CI workflows invoke Biome checks per app/service.
- Type-aware linting is desired, but tsgolint (typescript-go) has limitations (e.g.,
baseUrlin tsconfig). - Many generated artifacts are excluded in Biome and should remain excluded in Oxlint.
Desired Outcome
- Oxlint configured at the repo root with shared rules and ignore patterns.
- New scripts for Oxlint (non-type-aware and type-aware variants) added without removing existing lint scripts.
- Optional type-aware linting enabled per workspace based on tsconfig compatibility.
- CI runs Oxlint as an additional check (non-blocking or phased to blocking).
- Clear docs for developers on when/how to run Oxlint and how it coexists with Biome.
Scope
- In scope:
- Root Oxlint config (e.g.,
.oxlintrc.json) and ignore rules. - New lint scripts in root and workspace
package.jsonfiles. - CI workflow updates to add Oxlint checks.
- Lint-specific tsconfig(s) (as needed) to enable
--type-aware. - Docs updates describing dual-tool workflow.
- Root Oxlint config (e.g.,
- Out of scope:
- Removing or replacing Biome, ktlint, gofmt, buf, or other existing linters.
- Large-scale code reformatting.
- Changing production infra or ArgoCD manifests.
Constraints & Risks
- tsgolint/type-aware mode uses typescript-go and does not support some TS options (notably
baseUrl), which may require lint-only tsconfigs. - Oxlint config is JSON-only and nested configs do not merge; enforce a single canonical config.
- Avoid lint noise on generated or vendored files.
Rollout / Ops Notes
- Start with a pilot workspace (e.g.,
apps/froussardorpackages/codex) and run Oxlint side-by-side with existing lint. - Expand to remaining workspaces after tuning rules and ignore patterns.
- Consider non-blocking CI at first, then switch to blocking once stable.
Validation
-
bun run lint:oxlint(repo or workspace) passes on pilot workspace. -
bun run lint:oxlint:typepasses on pilot workspace where enabled. - Existing lint commands (Biome, ktlint, gofmt, buf) still pass.
- CI workflows include Oxlint step and stay green.
Codex Prompt
Implement Oxlint as a complementary JS/TS linter in this monorepo (do not replace existing tooling). Add root Oxlint config + ignore patterns mirroring current Biome excludes, install oxlint and oxlint-tsgolint, and add new lint scripts (e.g., lint:oxlint, lint:oxlint:type) alongside existing ones. Introduce lint-specific tsconfig(s) to enable oxlint --type-aware where compatible (avoid unsupported TS options like baseUrl). Update CI to run Oxlint as an additional check with phased enforcement. Update docs describing the dual-tool workflow. Focus on JS/TS workspaces only; do not touch infra or generated directories.
Additional Context
- Repo root
biome.jsonalready lists many generated file excludes; port these to Oxlint ignore patterns.