Skip to content

feat: migrate off Nx to Vite+ #155

Description

@chrisjwalk

Overview

Phase 2 of the migration spike from #147. Replace Nx task orchestration, ESLint, and Prettier with Vite+ tooling.

Phase 1 (Analog.js app build + content) is complete.


Changes required

  • Add package.json to each of the 7 libs (auth, counter, home, login, shared, todo, weather-forecast) so Vite Task can derive ordering from workspace dependencies
  • Run vp migrate --no-interactive from workspace root — rewrites Vitest imports to vite-plus/test, merges configs
  • Replace nx.json + project.json lint/test targets with run.tasks in vite.config.ts
  • Replace custom .NET Nx executors (tools/builders/dotnet-builder) with vp run task definitions calling dotnet CLI directly
  • Replace nxViteTsPaths() with vite-tsconfig-paths plugin (same behaviour, no Nx dependency)
  • Swap @nx/enforce-module-boundaries ESLint rule for a convention-only approach (TS path aliases already enforce boundaries)
  • Replace CI's nx affected with --filter + a git diff-based shell script

Toolchain delta

Removed Replaced by
All @nx/* packages vite-plus
ESLint + Prettier Oxlint + Oxfmt (Rust-based, ~50–100× faster)
nx.json + 9× project.json single vite.config.ts

Acceptance criteria

  • All @nx/* packages removed from package.json
  • vp dev, vp build, vp test all pass for all projects
  • Lint and format work via Oxlint + Oxfmt
  • .NET build/test still works via vp run
  • CI updated to use --filter instead of nx affected
  • All existing unit and e2e tests pass

References

Metadata

Metadata

Assignees

No one assigned

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions