angular-architect
jeffallan/claude-skills
Generates Angular 17+ standalone components, NgRx state management, RxJS patterns, and optimized routing for enterprise applications.
What is angular-architect?
Angular Architect is a specialist skill for building Angular 17+ applications with standalone components, signals, and enterprise-grade patterns. Use it when designing component architecture, setting up NgRx state management, implementing RxJS reactive patterns, configuring advanced routing, optimizing bundle performance, or writing comprehensive tests.
- Generates Angular 17+ standalone components with OnPush change detection and signals
- Configures advanced routing with lazy loading, guards, and resolvers
- Implements NgRx store, effects, selectors, and entity adapters for state management
- Applies RxJS patterns including proper subscription management with takeUntilDestroyed
- Optimizes bundle performance and verifies production builds
- Writes unit and integration tests with >85% coverage using TestBed
How to install angular-architect
npx skills add https://github.com/jeffallan/claude-skills --skill angular-architect- Angular 17 or higher
- Node.js and npm installed
- Basic understanding of standalone components and RxJS
- TypeScript with strict mode enabled
How to use angular-architect
- 1.Analyze your application requirements and identify component structure, state needs, and routing architecture
- 2.Design the architecture using standalone components and signals, planning state flow and NgRx store structure if needed
- 3.Implement features by generating standalone components with OnPush strategy and reactive patterns
- 4.Set up NgRx store, effects, and selectors; verify store hydration and action flow with Redux DevTools
- 5.Apply performance optimizations and run `ng build --configuration production` to verify bundle size
- 6.Write unit and integration tests with TestBed, ensuring >85% coverage threshold is met
Use cases
- Building new Angular 17+ applications with standalone component architecture
- Setting up NgRx state management for complex application state
- Implementing reactive patterns with RxJS observables and operators
- Configuring lazy-loaded feature modules with route guards
- Optimizing bundle size and performance in production builds
- Senior Angular developers
- Enterprise application architects
- Teams building Angular 17+ applications
- Developers implementing complex state management
- Performance-focused development teams
angular-architect FAQ
Use signals for local component state and computed values. Use observables for async operations, streams, and state management with NgRx. Combine them with `toSignal()` and `toObservable()` when needed.
Use `takeUntilDestroyed()` with the injected `DestroyRef` to automatically unsubscribe when the component is destroyed. Alternatively, use the `async` pipe in templates.
Use standalone feature stores with `createFeatureSelector` and `createSelector`. Verify store state with Redux DevTools before proceeding. Keep reducers pure and handle errors in effects.
Use lazy loading for feature modules, enable tree-shaking with OnPush change detection, use `trackBy` in *ngFor loops, and run `ng build --configuration production` to identify and flag regressions.
Aim for >85% code coverage. Write tests for components using TestBed, test services with mocked dependencies, and test NgRx effects and reducers separately.
Full instructions (SKILL.md)
Source of truth, from jeffallan/claude-skills.
name: angular-architect description: Generates Angular 17+ standalone components, configures advanced routing with lazy loading and guards, implements NgRx state management, applies RxJS patterns, and optimizes bundle performance. Use when building Angular 17+ applications with standalone components or signals, setting up NgRx stores, establishing RxJS reactive patterns, performance tuning, or writing Angular tests for enterprise apps. license: MIT metadata: author: https://github.com/Jeffallan version: "1.1.0" domain: frontend triggers: Angular, Angular 17, standalone components, signals, RxJS, NgRx, Angular performance, Angular routing, Angular testing role: specialist scope: implementation output-format: code related-skills: typescript-pro, test-master
Angular Architect
Senior Angular architect specializing in Angular 17+ with standalone components, signals, and enterprise-grade application development.
Core Workflow
- Analyze requirements - Identify components, state needs, routing architecture
- Design architecture - Plan standalone components, signal usage, state flow
- Implement features - Build components with OnPush strategy and reactive patterns
- Manage state - Setup NgRx store, effects, selectors as needed; verify store hydration and action flow with Redux DevTools before proceeding
- Optimize - Apply performance best practices and bundle optimization; run
ng build --configuration productionto verify bundle size and flag regressions - Test - Write unit and integration tests with TestBed; verify >85% coverage threshold is met
Reference Guide
Load detailed guidance based on context:
| Topic | Reference | Load When |
|---|---|---|
| Components | references/components.md | Standalone components, signals, input/output |
| RxJS | references/rxjs.md | Observables, operators, subjects, error handling |
| NgRx | references/ngrx.md | Store, effects, selectors, entity adapter |
| Routing | references/routing.md | Router config, guards, lazy loading, resolvers |
| Testing | references/testing.md | TestBed, component tests, service tests |
Key Patterns
Standalone Component with OnPush and Signals
import { ChangeDetectionStrategy, Component, computed, input, output, signal } from '@angular/core';
import { CommonModule } from '@angular/common';
@Component({
selector: 'app-user-card',
standalone: true,
imports: [CommonModule],
changeDetection: ChangeDetectionStrategy.OnPush,
template: `
<div class="user-card">
<h2>{{ fullName() }}</h2>
<button (click)="onSelect()">Select</button>
</div>
`,
})
export class UserCardComponent {
firstName = input.required<string>();
lastName = input.required<string>();
selected = output<string>();
fullName = computed(() => `${this.firstName()} ${this.lastName()}`);
onSelect(): void {
this.selected.emit(this.fullName());
}
}
RxJS Subscription Management with takeUntilDestroyed
import { Component, OnInit, inject } from '@angular/core';
import { takeUntilDestroyed } from '@angular/core/rxjs-interop';
import { UserService } from './user.service';
@Component({ selector: 'app-users', standalone: true, template: `...` })
export class UsersComponent implements OnInit {
private userService = inject(UserService);
// DestroyRef is captured at construction time for use in ngOnInit
private destroyRef = inject(DestroyRef);
ngOnInit(): void {
this.userService.getUsers()
.pipe(takeUntilDestroyed(this.destroyRef))
.subscribe({
next: (users) => { /* handle */ },
error: (err) => console.error('Failed to load users', err),
});
}
}
NgRx Action / Reducer / Selector
// actions
export const loadUsers = createAction('[Users] Load Users');
export const loadUsersSuccess = createAction('[Users] Load Users Success', props<{ users: User[] }>());
export const loadUsersFailure = createAction('[Users] Load Users Failure', props<{ error: string }>());
// reducer
export interface UsersState { users: User[]; loading: boolean; error: string | null; }
const initialState: UsersState = { users: [], loading: false, error: null };
export const usersReducer = createReducer(
initialState,
on(loadUsers, (state) => ({ ...state, loading: true, error: null })),
on(loadUsersSuccess, (state, { users }) => ({ ...state, users, loading: false })),
on(loadUsersFailure, (state, { error }) => ({ ...state, error, loading: false })),
);
// selectors
export const selectUsersState = createFeatureSelector<UsersState>('users');
export const selectAllUsers = createSelector(selectUsersState, (s) => s.users);
export const selectUsersLoading = createSelector(selectUsersState, (s) => s.loading);
Constraints
MUST DO
- Use standalone components (Angular 17+ default)
- Use signals for reactive state where appropriate
- Use OnPush change detection strategy
- Use strict TypeScript configuration
- Implement proper error handling in RxJS streams
- Use
trackByfunctions in*ngForloops - Write tests with >85% coverage
- Follow Angular style guide
MUST NOT DO
- Use NgModule-based components (except when required for compatibility)
- Forget to unsubscribe from observables (use
takeUntilDestroyedorasyncpipe) - Use async operations without proper error handling
- Skip accessibility attributes
- Expose sensitive data in client-side code
- Use
anytype without justification - Mutate state directly in NgRx
- Skip unit tests for critical logic
Output Templates
When implementing Angular features, provide:
- Component file with standalone configuration
- Service file if business logic is involved
- State management files if using NgRx
- Test file with comprehensive test cases
- Brief explanation of architectural decisions
Related skills
More from jeffallan/claude-skills and the wider catalog.

api-designer
Design REST and GraphQL APIs with OpenAPI 3.1 specifications, resource modeling, and versioning strategies.

architecture-designer
Design scalable system architecture, document decisions with ADRs, and evaluate technology trade-offs.

atlassian-mcp
Integrate Jira and Confluence via MCP protocol for issue tracking, documentation, and sprint management.

chaos-engineer
Design chaos experiments, failure injection frameworks, and game day exercises for resilient distributed systems.

cli-developer
Build production CLI tools with argument parsing, completions, and interactive prompts across Node.js, Python, and Go.

cloud-architect
Design cloud architectures, migration plans, cost optimization, and disaster recovery across AWS, Azure, and GCP.