Migrating the Bitwarden Web Vault from Angular to React using Plugins
We pointed our angular-to-react plugin at a real codebase: about 400 Angular components, 230 routes, about 311k lines of TypeScript, and a vault full of cryptography. Here is how 32 units went, and what we learned along the way.

Our Angular to React guide used a simple example app with two components. This time we pointed our angular-to-react Claude Code plugin at something real: the open-source Bitwarden web vault, about 400 Angular components, 230 routes and 311k lines of password-manager TypeScript with real cryptography in it.
This is the story of that run: what the plugin did, the decisions that mattered, the lessons we learned, and what we'd tell anyone about to try the same.
Context: this is a showcase fork of the public bitwarden/clients repo. Bitwarden isn't involved and no Bitwarden user runs this code. We picked it because it's large, well-tested, actively maintained Angular, the kind of codebase migrations usually stall on.
The size of the job
| Starting point | |
|---|---|
| Framework | Angular 21.2 with signals, Nx 22, webpack, zone.js |
| Components | 266 in the open-source web app, 130 in the commercial bit-web |
| TypeScript | About 311k lines across web and bit-web |
| Routes | About 230, with hash routing, named outlets and inherited params |
| Services | 216 providers in one shared module, plus 63 web overrides |
Scope was phase 1 only: the web vault. The browser extension and desktop app also run on Angular and share many of the same libraries, which turned out to be the hardest constraint of the whole project.
Where it stands: all 32 units are done, from scaffolding through the full shell flip and the final Angular UI cleanup. The Angular web app, the bridge and the Angular build configs are deleted. The migration touched about 2,300 files and produced 700 .tsx files and 230 React specs.
What the plugin brings
The angular-to-react plugin packages a migration method for Claude Code. It isn't a code converter. It's a workflow that keeps a long job on rails:
| Piece | What it did on this run |
|---|---|
/angular-to-react:plan | Assessed the repo, picked a strategy and wrote .migration/ (plan, decisions, state). It changed no app code until the plan was approved. |
angular-inventory agent | Three read-only sweeps: components, routes, services and DI, UI dependencies. They produced the numbers above. |
| The skill | One unit per run: "continue the migration" reads state.json, picks the next unit, does it, validates it and records the outcome. |
angular-parity-reviewer agent | Compared every React port with its Angular original and listed each behavior difference to fix or record as a quirk. |
| context7 MCP | Current React Router, React and TanStack docs, so ports use today's APIs rather than remembered ones. |
The .migration/ folder is the real product. It holds the plan, 64 dated decision records and a file per unit with packages, checklists, parity findings and leftovers. Any session, on any machine, can pick up exactly where the last one stopped. That mattered more than we expected: this run moved between a laptop and a remote build box, and between many separate Claude sessions.
Decision 1: run React inside the Angular app
Two traits of the Bitwarden web vault shaped the strategy:
- Hash routing. URLs look like
#/vault. A proxy or CDN never sees the fragment, so it can't send one route to React and another to Angular. - Keys live in memory. The vault keeps the decrypted user key in memory only. Every full page load between two apps would lock the vault.
So the plan chose a vertical slice strategy with branch by abstraction: React runs inside the Angular app, one route at a time. An Angular ReactRouteHost mounts a React page. A reactRoute() helper picks React or Angular per route behind a dev flag, and that flag is the rollback switch. That one decision shaped the next 30 units.

Decision 2: reuse the services, don't rewrite them
The inventory found the best news of the project: Bitwarden's service layer has zero Angular imports. Services are plain classes exposing RxJS observables. Only the wiring (safeProvider objects) is Angular.
So React never got its own copies. A small react-core library adds useService, useObservable and useI18n over a ServiceLocator. Until the shell flip, that locator simply asked Angular's injector, so React and Angular shared one session, one vault and one lock state. Later the same provider list moved into a plain container, and Angular left the startup path.

Lesson: before planning a frontend migration, find out how much of your logic is actually framework code. Here it was the UI and the wiring, not the domain. That turned a rewrite into a port.
32 units, leaves first, shell last
| Units | What moved |
|---|---|
| u01–u03 | Scaffold the React libs, build the bridge, and write Playwright smoke tests per route group against Angular before anything moves |
| u04–u11 | The component library in React: primitives, buttons, forms (react-hook-form), select, overlays (Radix), dialogs, layout and nav, and virtualized tables |
| u12–u24 | Feature areas: tools, importer, reports, settings, billing, registration and login, lock and keys, admin, members and collections |
| u25–u28 | Commercial bit-web: SSO and SCIM, Secrets Manager (45 components), providers, access intelligence (charts) |
| u29–u30 | The vault itself: item view and edit for every type, then the 1,700-line vault page |
| u31 | Shell flip: React Router owns the URLs, guards become loaders, React boots the services |
| u32 | Cutover: delete the Angular web app and the bridge, and gate the React build against Angular UI code |

Every unit followed the same test plan: port the Jest specs to React Testing Library, run the smoke tests with the flag off and on, run the parity reviewer against the originals, then lint and build. Each unit's file records which Angular-only specs had no React equivalent and why.

Five lessons from the run
The parity reviewer earns its keep
A careful port still drifts. The reviewer caught things a human skim misses: a dialog that must close when the vault locks, a re-run of ngOnInit that duplicated a row after sync, and route-level providers that couldn't see the page's route params, so opening an item from an org report hung with no error. Some differences were real Angular bugs. Those were kept for parity and logged as quirks, not silently fixed. Every difference was caught and resolved before its unit closed.
Shared libraries are the hard part
The web app is easy to delete. The libraries it shares with the browser extension and desktop app are not, because both still run on Angular. Every move leaves a re-export at the old path, and the browser and desktop builds run after each one. A build-time gate (check-no-angular.js) reads webpack stats and prints the exact import chain to cut whenever Angular code tries to reach the React build, which grep can't do.
Make scope decisions explicit
The browser extension and desktop app still need Angular's DI and signals inside the shared libraries. Rather than rewrite those libraries mid-project, the plugin recorded a clear decision: the React web vault may use @angular/core purely as a DI and signals runtime, with no compiler and no templates. Every other @angular/* package, zone.js and every component, module, directive and pipe stays out, enforced by the build gate. Replacing that runtime is planned as part of phase 2, alongside the extension and desktop apps.
Every check is recorded, not just its result
Each unit file records how every check was run (type checks, specs, smoke tests and the parity review), not only whether it passed. That makes the results reproducible and auditable by anyone who picks up the migration later.
State on disk makes long runs resumable
For the final unit we split the work into sub-packages and ran several Claude Code sessions in parallel, each in its own git worktree. Because every worker commits to its own branch and the .migration/ state lives on disk, sessions can be stopped, restarted or moved to another machine without losing any work.
Try it on your own codebase: install the angular-to-react plugin in Claude Code, open your Angular repo and run /angular-to-react:plan. It writes the plan and stops for your approval. Want help on a large migration? Start with a MigrateX assessment.
About MigrateX

MigrateX is our platform and service for moving software, data and infrastructure from one technology to another. It combines automation with experienced engineers. The automation does the repetitive work quickly, and the engineers make the tricky decisions, like how Angular and React share one session and which shared libraries need a seam first.
The angular-to-react plugin used on the Bitwarden web vault is the same method we run on MigrateX projects. Here's what that looks like in practice:
- Assessment. We inventory your Angular app: components, routes, services and DI, and UI dependencies. You see where the effort really sits before anyone commits to a timeline.
- Migration plan. Together with your team, we pick the strategy, the order of units and how Angular and React share services, sessions and translations along the way.
- Unit-by-unit migration. Automation ports components, specs and routes. Our engineers handle the parts that need judgement, like the bridge, the shell flip and shared libraries.
- Proof that it works. Smoke tests run against Angular before anything moves, and every unit passes them with React switched on, plus a parity review against the original.
- Handover and clean-up. We remove the bridge and the Angular web app, and leave your team with a React codebase they know and own.
What you get along the way:
- No big-bang release. Your app keeps running and shipping features while the migration happens route by route.
- Less risk. A per-route flag is the rollback switch, and you can pause at any point.
- A record you can audit. Every decision, unit and check lives in the
.migration/folder in your repo. - More than front ends. The same approach covers other frameworks, like Ember and Backbone, as well as data and infrastructure migrations.
Planning a move from Angular, or already partway through? Tell us a little about your app through Contact Us, or start with a MigrateX assessment.
References
From CobuildX
Codebase
- Bitwarden. bitwarden/clients (web, browser, desktop and CLI clients). https://github.com/bitwarden/clients
Further reading
- M. Fowler. Branch By Abstraction. martinfowler.com. https://martinfowler.com/bliki/BranchByAbstraction.html