Skip to content

chore: migrate from biome to oxfmt#1123

Open
B4nan wants to merge 5 commits into
masterfrom
chore/migrate-to-oxfmt
Open

chore: migrate from biome to oxfmt#1123
B4nan wants to merge 5 commits into
masterfrom
chore/migrate-to-oxfmt

Conversation

@B4nan
Copy link
Copy Markdown
Member

@B4nan B4nan commented May 5, 2026

Summary

Replaces Biome (formatter) with oxfmt, matching the toolchain in apify-storage-local-js, apify-shared-js, apify-client-js, apify-core, and crawlee. Stacked on #1122 (eslint→oxlint migration); will be retargeted to master once that lands.

Commits

  • chore: add oxfmt tooling — adds oxfmt@0.46.0 devDep, .oxfmtrc.json (printWidth 120, quoteProps preserve, the rest comes from .editorconfig), adds quote_type = single to .editorconfig so oxfmt picks up biome's previous quote style; drops @biomejs/biome and prettier (biome was the only consumer of prettier on this repo besides the markdown/yaml check, which we drop too — matches what other repos did when migrating). Swaps format / format:check and lint-staged to oxfmt.
  • chore: apply oxfmt formatting — pure oxfmt --write reformat across 39 files. Diff is mostly tab/quote/line-wrap normalization that biome and oxfmt disagreed on.

What changed (config side)

  • Drop @biomejs/biome, prettier
  • Add oxfmt@0.46.0
  • Replace biome.json with .oxfmtrc.json
  • Add quote_type = single to .editorconfig (oxfmt reads it; biome had it inline)
  • formatoxfmt --check, format:fixoxfmt
  • lint-staged runs oxfmt + oxlint --fix for code; markdown/yaml no longer auto-formatted (consistent with the other oxfmt'd repos)

Format output

$ pnpm format
oxfmt --check
All matched files use the correct format.
Finished in 18ms on 246 files using 14 threads.

Test plan

  • pnpm lint — clean
  • pnpm format — clean
  • pnpm build — TypeScript + tsdown both succeed

Follow-up

Once this lands, add the chore: apply oxfmt formatting commit SHA to a .git-blame-ignore-revs file so blame skips it.

@B4nan B4nan requested a review from vladfrangu as a code owner May 5, 2026 20:34
@B4nan B4nan added the adhoc Ad-hoc unplanned task added during the sprint. label May 5, 2026
Base automatically changed from chore/migrate-to-oxlint to master May 6, 2026 12:31
@B4nan B4nan force-pushed the chore/migrate-to-oxfmt branch from 64c3795 to b8db9b9 Compare May 6, 2026 12:34
@github-actions github-actions Bot added this to the 140th sprint - Tooling team milestone May 6, 2026
@github-actions github-actions Bot added the t-tooling Issues with this label are in the ownership of the tooling team. label May 6, 2026
@B4nan B4nan requested a review from l2ysho May 6, 2026 12:43
Copy link
Copy Markdown
Contributor

@l2ysho l2ysho left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🚀

@B4nan B4nan force-pushed the chore/migrate-to-oxfmt branch from 165cdd8 to 62926c8 Compare May 11, 2026 15:50
B4nan and others added 2 commits May 11, 2026 18:21
…nt-staged oxlint

- oxfmt 0.46.0 → 0.48.0 (no formatting change on the current tree)
- oxlint 1.62.0 → 1.63.0
- oxlint-tsgolint 0.22.0 → 0.22.1
- @apify/oxlint-config ^0.2.5 → ^0.2.9
- lint-staged: mirror the `--no-error-on-unmatched-pattern` flag already
  used for oxfmt onto the oxlint command, so staging a file that the
  glob matches but oxlint's own ignore config skips no longer fails
  the hook.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
Mirrors the import-sort config landing in apify-core (#27779):

    side_effect  →  builtin  →  external
                 →  @apify/*  →  @apify-packages/*
                 →  [parent, sibling, index]

Custom groups use `modifiers: ["value"]` and a separate `type` selector
so type imports of `@apify/*` / `@apify-packages/*` land in the same
group as their value counterparts.

Reformats 2 files where the alphabetical order within an existing
group was off.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
@B4nan B4nan force-pushed the chore/migrate-to-oxfmt branch from b68bc73 to 53a9388 Compare May 11, 2026 16:51
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

adhoc Ad-hoc unplanned task added during the sprint. t-tooling Issues with this label are in the ownership of the tooling team.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants