Skip to content

[skip chg] Migrate linting and formatting to oxc - #439

Merged
timotheeguerin merged 3 commits into
mainfrom
migrate-to-oxc
Jul 15, 2026
Merged

[skip chg] Migrate linting and formatting to oxc#439
timotheeguerin merged 3 commits into
mainfrom
migrate-to-oxc

Conversation

@timotheeguerin

Copy link
Copy Markdown
Collaborator

Replaces ESLint with oxlint (+ oxlint-tsgolint for type-aware linting) and Prettier with oxfmt.

Linting (ESLint → oxlint)

  • New .oxlintrc.json mirroring the previous ESLint config (same custom rules, ignores, trace-cli no-console override, and the vitest test-file rules).
  • Type-aware linting is enabled via --type-aware, but scoped to only no-floating-promises to preserve the previous behavior; all other type-aware rules are disabled (see comments in the config for how to opt back in).
  • packages/devtools migrated to oxlint using the react-hooks plugin.
  • Removed all ESLint dependencies and eslint.config.js files.

Formatting (Prettier → oxfmt)

  • New .oxfmtrc.json (printWidth: 80, sortImports, sortPackageJson: false), with the Prettier ignore patterns migrated over.
  • Removed prettier / prettier-plugin-organize-imports.
  • The bulk reformat is isolated in its own commit (style: apply oxfmt formatting). Main visible changes: ternaries revert from experimentalTernaries to the standard style, and imports are grouped via sortImports.

Other

  • Updated the pnpm catalog, root scripts, and VSCode settings/extensions (oxc.oxc-vscode).
  • Added @types/node at the root so type-aware linting can resolve types: ["node"].
  • Removed one unreachable return surfaced by oxlint (csharp symbols).

Verified

build, lint (root + devtools), format:check, and sync-publish-config:check all pass.

@github-actions

github-actions Bot commented Jul 15, 2026

Copy link
Copy Markdown
Contributor

❌ There is undocummented changes. Run chronus add to add a changeset or click here.

The following packages have changes but are not documented.

  • @alloy-js/babel-plugin
  • @alloy-js/cli
  • @alloy-js/core
  • @alloy-js/create
  • @alloy-js/csharp
  • @alloy-js/go
  • @alloy-js/java
  • @alloy-js/json
  • @alloy-js/markdown
  • @alloy-js/msbuild
  • @alloy-js/python
  • @alloy-js/trace-cli
  • @alloy-js/typescript
Show changes

Replace ESLint with oxlint (+ oxlint-tsgolint for type-aware linting) and
Prettier with oxfmt.

- Add .oxlintrc.json mirroring the previous ESLint rules. Type-aware linting
  is enabled via --type-aware but scoped to only no-floating-promises to match
  the previous behavior; all other type-aware rules are disabled.
- Add .oxfmtrc.json (printWidth 80, sortImports, sortPackageJson off) and
  migrate the Prettier ignore patterns.
- Migrate the devtools package to oxlint (react-hooks plugin).
- Update catalog, scripts, VSCode settings/extensions.
- Remove an unreachable return surfaced by oxlint (csharp symbols).
Reformat the repository with oxfmt (replacing Prettier). Mostly ternary
style changes (oxfmt does not support experimentalTernaries) and import
grouping via sortImports.
@timotheeguerin timotheeguerin changed the title Migrate linting and formatting to oxc [skip chg] Migrate linting and formatting to oxc Jul 15, 2026
@timotheeguerin
timotheeguerin marked this pull request as ready for review July 15, 2026 18:46
@timotheeguerin
timotheeguerin merged commit 6b26118 into main Jul 15, 2026
9 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.

1 participant