Agent skill

AngularJS to Angular Migration

by wshobson in wshobson/agents

Guides migrating AngularJS 1.x apps to modern Angular: choosing a strategy, running a hybrid app with ngUpgrade, and converting controllers, directives and services.

MITAuto-check passedDevelopment

Install AngularJS to Angular Migration

skills CLI
$ npx skills add wshobson/agents --skill angular-migration -a claude-code

Project install by default; add -g for ~/.claude/skills/.

GitHub CLI
$ gh skill install wshobson/agents angular-migration --agent claude-code

Project scope by default; add --scope user for a personal install. Needs GitHub CLI 2.90.0 or later (public preview).

Manual copy
$ git clone --depth 1 https://github.com/wshobson/agents.git skills-src && mkdir -p .claude/skills && cp -r skills-src/plugins/framework-migration/skills/angular-migration .claude/skills/angular-migration && rm -rf skills-src

Use ~/.claude/skills/ instead of .claude/skills for a personal install. The folder must contain SKILL.md.

Claude Code skills documentation · loads skills from .claude/skills/

Facts

Skill name
angular-migration
GitHub stars
40k
Used in
10 other repos
Token cost
~1.8k tokens
SKILL.md length
170 words
Files
2 (incl. references)
Skills in repo
142
Repo updated
First seen
Licence
MIT

At a glance

Guides migrating AngularJS 1.x apps to modern Angular: choosing a strategy, running a hybrid app with ngUpgrade, and converting controllers, directives and services.

  • Works in 3 steps: Big Bang (Complete Rewrite) → Incremental (Hybrid Approach) → Vertical Slice
  • Planning the move of an AngularJS 1.x application to Angular
  • SKILL.md covers When to Use This Skill, Migration Strategies, Hybrid App Setup and Component Migration, plus 4 more sections
  • Instructions only: no scripts, shell commands, URLs or credentials in SKILL.md

What it does

The skill compares three migration strategies: a big-bang rewrite for small or greenfield apps, an incremental hybrid approach for large apps that need continuous delivery, and a vertical-slice approach that migrates one feature at a time. It then shows how to bootstrap a hybrid app with the upgrade module so AngularJS and Angular run side by side.

Code examples show before-and-after conversions of AngularJS controllers, directives and services into Angular components and injectable services, and a section on dependency injection covers downgrading Angular pieces for use in AngularJS. Routing migration and updating to recent Angular versions are listed among the topics, and a details reference file extends the examples. The excerpt ends in the dependency injection section.

When your agent uses it

  • Planning the move of an AngularJS 1.x application to Angular
  • Running AngularJS and Angular side by side in a hybrid app
  • Converting AngularJS controllers and directives into Angular components
  • Replacing AngularJS factories with injectable Angular services

Example prompts

  • “Plan an incremental migration of our AngularJS 1.x admin app to Angular using a hybrid setup.”
  • “Convert the userCard directive to an Angular component with an input and an output event.”
  • “Rewrite the UserService factory as an injectable Angular service using HttpClient.”

Workflow steps

3 steps, taken from the step headings in SKILL.md.

  1. Big Bang (Complete Rewrite)
  2. Incremental (Hybrid Approach)
  3. Vertical Slice

What it can do on your machine

Read from SKILL.md and the folder at commit 46891e7. It shows what the files ask for, not the result of running them.

  • Tool permissions

    Pre-approves nothing: there is no allowed-tools line, so your agent's usual permission prompts apply.

    From allowed-tools in the SKILL.md frontmatter.

  • Runs code

    No scripts in the folder and no shell commands in SKILL.md (its code samples are typescript and javascript).

    From the folder's file list and the shell code blocks in SKILL.md.

  • Network

    No URLs in SKILL.md.

    From URLs in SKILL.md, links to its own repository left out.

  • Credentials

    Names no API keys, tokens, secrets or passwords.

    From names ending in _API_KEY, _TOKEN, _SECRET, _KEY or _PASSWORD in SKILL.md.

Context cost

AngularJS to Angular Migration loads about 1.8k tokens when it runs, and up to ~2.2k if it reads all its reference files. Until then it costs about 62 tokens; SKILL.md has 170 words of instructions outside code blocks.

Always · name and description, kept in context so the agent knows when to use it
~62
When it runs · the whole SKILL.md, loaded when a task matches
~1.8k
With references · SKILL.md plus every file in references/, read only if the agent opens them
~2.2k

Estimates: characters ÷ 4, the usual rule of thumb; real counts depend on the model's tokenizer. Scripts and assets cost tokens only if the agent reads them.

Safety

Auto-check passed

The automated check found no risky patterns in SKILL.md.

Automated static check — not a guarantee. Review scripts before installing. It scans the text of SKILL.md for risky patterns (piping downloads into a shell, reading credential files, hidden Unicode, destructive commands); files beside SKILL.md are not scanned.

SKILL.md

The full file from wshobson/agents at commit 46891e7, republished under its MIT licence (© wshobson). 170 words, ~1,781 tokens.

Download SKILL.mdSave it as .claude/skills/angular-migration/SKILL.md (or your agent's skills folder). This skill also uses 1 other file; get the full folder from GitHub.
name
angular-migration
description
Migrate from AngularJS to Angular using hybrid mode, incremental component rewriting, and dependency injection updates. Use when upgrading AngularJS applications, planning framework migrations, or modernizing legacy Angular code.

Angular Migration

Master AngularJS to Angular migration, including hybrid apps, component conversion, dependency injection changes, and routing migration.

When to Use This Skill

  • Migrating AngularJS (1.x) applications to Angular (2+)
  • Running hybrid AngularJS/Angular applications
  • Converting directives to components
  • Modernizing dependency injection
  • Migrating routing systems
  • Updating to latest Angular versions
  • Implementing Angular best practices

Migration Strategies

1. Big Bang (Complete Rewrite)
  • Rewrite entire app in Angular
  • Parallel development
  • Switch over at once
  • Best for: Small apps, green field projects
2. Incremental (Hybrid Approach)
  • Run AngularJS and Angular side-by-side
  • Migrate feature by feature
  • ngUpgrade for interop
  • Best for: Large apps, continuous delivery
3. Vertical Slice
  • Migrate one feature completely
  • New features in Angular, maintain old in AngularJS
  • Gradually replace
  • Best for: Medium apps, distinct features

Hybrid App Setup

typescript
// main.ts - Bootstrap hybrid app
import { platformBrowserDynamic } from "@angular/platform-browser-dynamic";
import { UpgradeModule } from "@angular/upgrade/static";
import { AppModule } from "./app/app.module";

platformBrowserDynamic()
  .bootstrapModule(AppModule)
  .then((platformRef) => {
    const upgrade = platformRef.injector.get(UpgradeModule);
    // Bootstrap AngularJS
    upgrade.bootstrap(document.body, ["myAngularJSApp"], { strictDi: true });
  });
typescript
// app.module.ts
import { NgModule } from "@angular/core";
import { BrowserModule } from "@angular/platform-browser";
import { UpgradeModule } from "@angular/upgrade/static";

@NgModule({
  imports: [BrowserModule, UpgradeModule],
})
export class AppModule {
  constructor(private upgrade: UpgradeModule) {}

  ngDoBootstrap() {
    // Bootstrapped manually in main.ts
  }
}

Component Migration

AngularJS Controller → Angular Component
javascript
// Before: AngularJS controller
angular
  .module("myApp")
  .controller("UserController", function ($scope, UserService) {
    $scope.user = {};

    $scope.loadUser = function (id) {
      UserService.getUser(id).then(function (user) {
        $scope.user = user;
      });
    };

    $scope.saveUser = function () {
      UserService.saveUser($scope.user);
    };
  });
typescript
// After: Angular component
import { Component, OnInit } from "@angular/core";
import { UserService } from "./user.service";

@Component({
  selector: "app-user",
  template: `
    <div>
      <h2>{{ user.name }}</h2>
      <button (click)="saveUser()">Save</button>
    </div>
  `,
})
export class UserComponent implements OnInit {
  user: any = {};

  constructor(private userService: UserService) {}

  ngOnInit() {
    this.loadUser(1);
  }

  loadUser(id: number) {
    this.userService.getUser(id).subscribe((user) => {
      this.user = user;
    });
  }

  saveUser() {
    this.userService.saveUser(this.user);
  }
}
AngularJS Directive → Angular Component
javascript
// Before: AngularJS directive
angular.module("myApp").directive("userCard", function () {
  return {
    restrict: "E",
    scope: {
      user: "=",
      onDelete: "&",
    },
    template: `
      <div class="card">
        <h3>{{ user.name }}</h3>
        <button ng-click="onDelete()">Delete</button>
      </div>
    `,
  };
});
typescript
// After: Angular component
import { Component, Input, Output, EventEmitter } from "@angular/core";

@Component({
  selector: "app-user-card",
  template: `
    <div class="card">
      <h3>{{ user.name }}</h3>
      <button (click)="delete.emit()">Delete</button>
    </div>
  `,
})
export class UserCardComponent {
  @Input() user: any;
  @Output() delete = new EventEmitter<void>();
}

// Usage: <app-user-card [user]="user" (delete)="handleDelete()"></app-user-card>

Service Migration

javascript
// Before: AngularJS service
angular.module("myApp").factory("UserService", function ($http) {
  return {
    getUser: function (id) {
      return $http.get("/api/users/" + id);
    },
    saveUser: function (user) {
      return $http.post("/api/users", user);
    },
  };
});
typescript
// After: Angular service
import { Injectable } from "@angular/core";
import { HttpClient } from "@angular/common/http";
import { Observable } from "rxjs";

@Injectable({
  providedIn: "root",
})
export class UserService {
  constructor(private http: HttpClient) {}

  getUser(id: number): Observable<any> {
    return this.http.get(`/api/users/${id}`);
  }

  saveUser(user: any): Observable<any> {
    return this.http.post("/api/users", user);
  }
}

Dependency Injection Changes

Downgrading Angular → AngularJS
typescript
// Angular service
import { Injectable } from "@angular/core";

@Injectable({ providedIn: "root" })
export class NewService {
  getData() {
    return "data from Angular";
  }
}

// Make available to AngularJS
import { downgradeInjectable } from "@angular/upgrade/static";

angular.module("myApp").factory("newService", downgradeInjectable(NewService));

// Use in AngularJS
angular.module("myApp").controller("OldController", function (newService) {
  console.log(newService.getData());
});
Upgrading AngularJS → Angular
typescript
// AngularJS service
angular.module('myApp').factory('oldService', function() {
  return {
    getData: function() {
      return 'data from AngularJS';
    }
  };
});

// Make available to Angular
import { InjectionToken } from '@angular/core';

export const OLD_SERVICE = new InjectionToken<any>('oldService');

@NgModule({
  providers: [
    {
      provide: OLD_SERVICE,
      useFactory: (i: any) => i.get('oldService'),
      deps: ['$injector']
    }
  ]
})

// Use in Angular
@Component({...})
export class NewComponent {
  constructor(@Inject(OLD_SERVICE) private oldService: any) {
    console.log(this.oldService.getData());
  }
}

Routing Migration

javascript
// Before: AngularJS routing
angular.module("myApp").config(function ($routeProvider) {
  $routeProvider
    .when("/users", {
      template: "<user-list></user-list>",
    })
    .when("/users/:id", {
      template: "<user-detail></user-detail>",
    });
});
typescript
// After: Angular routing
import { NgModule } from "@angular/core";
import { RouterModule, Routes } from "@angular/router";

const routes: Routes = [
  { path: "users", component: UserListComponent },
  { path: "users/:id", component: UserDetailComponent },
];

@NgModule({
  imports: [RouterModule.forRoot(routes)],
  exports: [RouterModule],
})
export class AppRoutingModule {}

Additional patterns and templates

More detailed templates and worked examples live in references/details.md. Read that file for the full pattern library.

© wshobson, MIT. Rendered from Markdown: HTML in the file is shown as text, images as links, and headings moved down two levels. Raw file

Files

SKILL.md and 1 other file (references) in plugins/framework-migration/skills/angular-migration of wshobson/agents.

  • SKILL.md
  • references/details.md

Open the folder on GitHubat commit 46891e7

Used in 10 other repositories

We found 24 copies of this SKILL.md (exact, near-identical or edited) in other folders, from 10 other GitHub owners. This page covers the copy in wshobson/agents, which our catalogue first saw on October 7, 2026.

Compare with similar skills

AngularJS to Angular Migration next to the 5 skills that share the most tags, products or categories with it. Stars are the repository's; “used in” counts other GitHub owners with a copy.

AngularJS to Angular Migration compared with similar skills
SkillStarsUsed inTokensAuto-checkLicenceRepo updated
AngularJS to Angular Migration this skillwshobson/agents40k10 repos~1.8kAutomated safety check: PassMIT
Convert Internal Package to TypeScriptTryGhost/Ghost55k—~1.2kAutomated safety check: PassMIT
jscpd Code Migration Trackerkucherenko/jscpd6.3k—~5kAutomated safety check: PassMIT
Creating Docs Code Exampleshandsontable/handsontable22k—~2.2kAutomated safety check: PassCustom licence
Zardzard-ui/zardui1.2k—~3.8kAutomated safety check: PassMIT
Codemod Generatormurphytrueman/design-system-ops201—~4.9kAutomated safety check: PassMIT

Similar skills

  • Moves a legacy internal Ghost package from JavaScript and CommonJS to TypeScript and ESM in three focused commits that keep git file history intact.

    55k GitHub stars~1.2k tokensUpdated today
    DevelopmentAuto-check passed
  • Measures a code port between languages or frameworks with jscpd's function-level comparison, porting tests before code and tracking what is left unmatched.

    6.3k GitHub stars~5k tokensUpdated today
    DevelopmentAuto-check passed
  • Creating Docs Code Examples

    handsontable/handsontable

    Sets the rules for writing Handsontable documentation examples in JavaScript, TypeScript, React, Angular and Vue, with the imports, registration and licence key each needs.

    22k GitHub stars~2.2k tokensUpdated today
    DevelopmentAuto-check passed
  • Zard

    zard-ui/zardui

    Manages zard/ui components and projects — adding, composing, styling, and debugging Angular UI built on TailwindCSS v4.

    1.2k GitHub stars~3.8k tokensUpdated today
    DevelopmentAuto-check passed
  • Codemod Generator

    murphytrueman/design-system-ops

    Generate tested jscodeshift/postcss codemods for design system migrations: token renames, prop renames or removals, import paths, component swaps.

    201 GitHub stars~4.9k tokensUpdated 13 days ago
    DevelopmentAuto-check passed
  • Angular Idioms and Patterns

    irahardianto/awesome-agv

    Coding conventions for Angular 19 and later: standalone components, signals, OnPush change detection, lazy routes and where RxJS still belongs.

    157 GitHub stars~3.8k tokensUpdated 2 days ago
    Frontend & DesignAuto-check passed

More from wshobson/agents

All 142 skills in this repo
  • Cuts cloud spend across AWS, Azure, GCP and OCI with cost tagging, rightsizing, commitment and spot pricing models, and architecture changes.

    40k GitHub starsUsed in 13 repos~1.7k tokens
    Auto-check passed
  • Billing Automation

    wshobson/agents

    Covers building subscription billing: billing cycles, subscription states, invoice generation, proration, tax handling and dunning for failed payments.

    40k GitHub starsUsed in 12 repos~473 tokens
    Auto-check passed
  • Profiles slow Python code with cProfile and memory profilers, then applies targeted fixes for CPU, memory, I/O and query bottlenecks.

    40k GitHub starsUsed in 12 repos~814 tokens
    Auto-check passed
  • Portfolio Risk Metrics

    wshobson/agents

    Covers portfolio risk measurement with VaR, CVaR, Sharpe, Sortino and drawdown, plus guidance on limits, stress tests and tail risk.

    40k GitHub starsUsed in 12 repos~502 tokens
    Auto-check passed
  • Plans memory headroom, works through out-of-memory failures and watches temperature and power during long ML training jobs on NVIDIA DGX Spark.

    40k GitHub starsUsed in 1 repo~2k tokens
    Auto-check passed
  • Writes unit tests for shell scripts with Bats: error-condition tests, fixtures and mocks, cross-shell checks, parallel runs, helper files and CI integration.

    40k GitHub starsUsed in 11 repos~1.3k tokens
    Auto-check passed

Questions about AngularJS to Angular Migration

What does AngularJS to Angular Migration do?

Guides migrating AngularJS 1.x apps to modern Angular: choosing a strategy, running a hybrid app with ngUpgrade, and converting controllers, directives and services. The skill compares three migration strategies: a big-bang rewrite for small or greenfield apps, an incremental hybrid approach for large apps that need continuous delivery, and a vertical-slice approach that migrates one feature at a time. It then shows how to bootstrap a hybrid app with the upgrade module so AngularJS and Angular run side by side.

When should I use AngularJS to Angular Migration?

AngularJS to Angular Migration fits situations like: planning the move of an AngularJS 1.x application to Angular; running AngularJS and Angular side by side in a hybrid app; converting AngularJS controllers and directives into Angular components; replacing AngularJS factories with injectable Angular services.

How do I install AngularJS to Angular Migration in Claude Code?

Run `npx skills add wshobson/agents --skill angular-migration -a claude-code`. Or copy the skill folder (plugins/framework-migration/skills/angular-migration in wshobson/agents) into .claude/skills/angular-migration in your project. Claude Code loads it when a task matches its description.

How do I install AngularJS to Angular Migration in Codex?

Run `npx skills add wshobson/agents --skill angular-migration -a codex`. Or copy the skill folder (plugins/framework-migration/skills/angular-migration in wshobson/agents) into .agents/skills/angular-migration in your project. Codex loads it when a task matches its description.

Can I use AngularJS to Angular Migration in Cursor, Gemini CLI or GitHub Copilot?

Cursor, Gemini CLI, GitHub Copilot and OpenCode also load SKILL.md folders. With the skills CLI, run `npx skills add wshobson/agents --skill angular-migration -a cursor` (or -a gemini-cli, github-copilot or opencode for the others). To copy it by hand, put the folder in .cursor/skills/angular-migration, .gemini/skills/angular-migration, .github/skills/angular-migration and .opencode/skills/angular-migration in your project.

What does AngularJS to Angular Migration need to run?

SKILL.md names no scripts, command-line tools or credentials: AngularJS to Angular Migration is instructions for the agent only.

Does AngularJS to Angular Migration access the network?

SKILL.md contains no URLs. Any network use would come from the scripts or tools the agent runs. This is read from the text; nothing was executed.

Is AngularJS to Angular Migration safe to install?

Our automated static check of SKILL.md found no risky patterns, such as piping downloads into a shell, reading credential files or hidden Unicode. It is not a guarantee. Review the folder before installing.

What licence does AngularJS to Angular Migration use?

AngularJS to Angular Migration is published under the MIT licence (the repository's licence). It allows redistribution, so the full SKILL.md is shown on this page.

How many tokens does AngularJS to Angular Migration use?

About 1.8k tokens (SKILL.md is roughly 7.1k characters). Agents keep only the skill's name and description in context until a task matches; then they load SKILL.md in full. Its references folder adds about 455 tokens, read only when the agent opens those files.

What are the alternatives to AngularJS to Angular Migration?

Skills that share tags, products or a category with AngularJS to Angular Migration: Convert Internal Package to TypeScript (TryGhost/Ghost, 55k stars), jscpd Code Migration Tracker (kucherenko/jscpd, 6.3k stars), Creating Docs Code Examples (handsontable/handsontable, 22k stars) and Zard (zard-ui/zardui, 1.2k stars). The comparison table on this page puts their stars, adoption, token cost, safety result and licence side by side.

Who maintains AngularJS to Angular Migration?

wshobson (a GitHub user) maintains it in wshobson/agents, which has 40,254 GitHub stars. The repository holds 142 skills in this directory. The repository was last updated on October 5, 2026.

Source: wshobson/agents on GitHub. Facts on this page come from the repository at the commit we read; the author's words are quoted as theirs.