Skip to content

Also migrate dynamic Oxlint & Oxfmt configurations if they exist #2430

Description

@KTrain5169

Description

From what I can see it seems like oxlint.config.ts and oxfmt.config.ts doesn't have a migration flow yet. This seems like a bit of low-hanging fruit.

Suggested solution

Probably replicate how Vitest & tsdown are migrated.

Alternative

Manual migration, but we already have their .ox*rc.json(c) versions migratable, why not these ones too?

Additional context

No response

Validations

  • Read the Contributing Guidelines.
  • Confirm this request is for Vite+ itself and not for Vite, Vitest, tsdown, Rolldown, or Oxc.
  • Check that there isn't already an issue requesting the same feature.

Activity

  1. added this to the RC milestone on Aug 14, 2026
  2. simulacre7 commented on Aug 21, 2026

    @simulacre7
    Contributor

    I'd like to take this one. Withdrawn — I missed that #2483 already implements this. Leaving my empirical findings as review feedback over there.

  3. fengmk2 commented on Oct 14, 2026

    @fengmk2
    Member

    The v1.2.0 ecosystem smoke test shows what the missing JS-config migration costs today. Each case also reproduces with the v1.1.0 migrate.

    • Migrate removes devDependencies the configs import. oxfmt, oxlint, and oxlint-tsgolint are dropped from package.json even though oxfmt.config.ts, oxlint.config.ts, or project scripts import them, because detection only recognizes .oxfmtrc / .oxlintrc JSON files. react-doctor resolves oxlint at runtime and its rule-registry script imports oxfmt (PR); dotabod-backend's configs import them (PR).
    • Migrate writes fmt: {} and ignores oxfmt.config.ts, so its own formatting pass uses defaults (double quotes, semicolons) and a project with single quotes and no semicolons fails vp fmt --check on every file migrate touched (115 to 134 files). dotabod-frontend (PR), dotabod-backend (PR).
    • The project's existing vp fmt --config oxfmt.config.ts scripts stop working: Failed to load configuration file. Expected a \fmt` field in the default export of oxfmt.config.ts. The workaround is pointing vite.config.ts fmtat the config and runningvp fmtwithout--config`.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Fields

    Priority

    None yet

    Start date

    None yet

    Target date

    None yet

    Effort

    None yet

    Projects

    No projects

      Milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions