angular-component-patterns
БесплатноБез исполняемых скриптовНе проверенStandards for OnPush components and strict Signals usage. Use when applying OnPush change detection or implementing Signals in Angular components. (triggers…
от ComeOnOliver★ 67 звёзд на GitHubОб этом скилле
Angular Component Expert
Priority: P0 (CRITICAL)
You are an Angular Architect. Enforce OnPush and Reactive patterns.
Implementation Guidelines
- Change Detection: ALWAYS uses ChangeDetectionStrategy.OnPush. No exceptions. Never use default change detection — it re-checks every component on every event. Component only re-renders when Signal inputs change or Signals fire.
- Inputs: Use signal() for mutable local state, input.required
() or input() instead of @Input(). Signal inputs are reactive — reference them as functions in templates: {{ userId() }}. Use booleanAttribute or numberAttribute transforms for primitive coercion. - State: Use Signals for local state, computed() for derived state, and effect() only for side effects. Delegate shared state to a Signal Store or Service.
- Smart/Dumb: Smart (Container) (inject services, manage state) -> Presentational (Dumb) (inputs/outputs only, no service dependencies, inputs and emit events via outputs) split. This Separates data concerns from rendering and makes components testable.
Verification Checklist (Mandatory)
- OnPush: Is
ChangeDetectionStrategy.OnPushset? - Async Pipe: Is
asyncpipe used in template? (No.subscribe()). - Signals: Are computed() signals used for derived values? (It caches the result).
- Leaks: DestroyRef, toSignal(), or takeUntilDestroyed() used?
Anti-Patterns
- No Default Change Detection: Eats performance. OnPush only.
- No Function Calls in Template: Never call functions in templates:
{{ calculate() }}-> usecomputed(). - No Manual Subscribe: Use
asyncpipe ortoSignal. Never call subscribe() in ngOnInit without a cleanup strategy.
References
Установить angular-component-patterns в Claude Code и Claude Desktop
Зарегайся, чтобы установить скилл
Создай бесплатный аккаунт, чтобы открыть команду установки и сохранить скилл в библиотеку.
- Открой команду установки в одну строку
- Сохраняй скиллы в синхронизируемую библиотеку
- Уведомления, когда скиллы обновляются
Разрешённые инструменты
Инструменты, которые скиллу разрешено вызывать.
Без ограничений — скилл может использовать любой инструмент.
FAQ
Что делает скилл angular-component-patterns?
Standards for OnPush components and strict Signals usage. Use when applying OnPush change detection or implementing Signals in Angular components. (triggers: **/*.component.ts, **/*.component.html, ChangeDetectionStrategy, OnPush, Input, Output)
Как установить скилл angular-component-patterns?
Скопируй папку скилла в ~/.claude/skills (вкладка Claude Code выше делает это одной командой), либо поставь как плагин.
Скилл angular-component-patterns запускает скрипты?
Нет, скилл состоит только из инструкций (SKILL.md), без исполняемых скриптов.
Похожие скиллы
theme-factory
Toolkit for styling artifacts with a theme. These artifacts can be slides, docs, reportings, HTML landing pages, etc. There are 10 pre-set themes with…
от Anthropicaccess
Manage Discord channel access — approve pairings, edit allowlists, set DM/group policy. Use when the user asks to pair, approve someone, check who's allowed…
от Anthropicconfigure
Set up the Discord channel — save the bot token and review access policy. Use when the user pastes a Discord bot token, asks to configure Discord, asks "how…
от Anthropicaccess
Manage iMessage channel access — approve pairings, edit allowlists, set DM/group policy. Use when the user asks to pair, approve someone, check who's allowed…
от Anthropic