angular-components
ALWAYS use when working with Angular Components, component architecture, @Component decorator, inputs, outputs, or component design patterns.
- License 许可
- MIT
- 最近更新
- 2026-06-10
- Stars
- ★ 3
- Forks
- 0
01 前言 Front Matter
- name
- angular-components
- metadata
- { "version": "21.0.0", "generated_at": 1771459200000, "generated_by": "oguzhancart" }
- description
- ALWAYS use when working with Angular Components, component architecture, @Component decorator, inputs, outputs, or component design patterns.
03 SKILL.md 正文
Angular Components
Version: Angular 21 (2025) Tags: Components, @Component, Architecture
References: Components Guide • @Component API
Best Practices
- Create standalone component
@Component({
standalone: true,
selector: 'app-my',
imports: [CommonModule],
template: `<p>Content</p>`
})
export class MyComponent {}
- Use inputs with signals
@Component({})
export class MyComponent {
data = input<string>('');
required = input.required<User>();
computed = computed(() => this.data()?.name);
}
- Use outputs for events
@Component({})
export class MyComponent {
data = output<string>();
onClick() {
this.data.emit('event');
}
}
- Use template reference variables
@Component({
template: `
<input #nameInput>
<button (click)="onSubmit(nameInput.value)">Submit</button>
`
})
export class MyComponent {}
- Use content projection
@Component({
selector: 'app-card',
template: `
<div class="header">
<ng-content select="[header]"></ng-content>
</div>
<div class="body">
<ng-content></ng-content>
</div>
`
})
export class CardComponent {}
- Use change detection strategy
@Component({
changeDetection: ChangeDetectionStrategy.OnPush
})
export class OptimizedComponent {}
- Use encapsulation
@Component({
encapsulation: ViewEncapsulation.None // or Emulated, ShadowDom
})
export class StyledComponent {}
- Use host binding
@Component({
host: {
'[class.active]': 'isActive',
'(click)': 'onClick()'
}
})
export class HostComponent {
isActive = false;
}
04 同仓库更多 Skills
youtube-content
YouTube transcripts to summaries, threads, blogs.
xurl
X/Twitter via xurl CLI: post, search, DM, media, v2 API.
touchdesigner-mcp
Control a running TouchDesigner instance via twozero MCP — create operators, set parameters, wire connections, execute Python, build real-time visuals. 36 native tools.
test-driven-development
TDD: enforce RED-GREEN-REFACTOR, tests before code.
teams-meeting-pipeline
Operate the Teams meeting summary pipeline via Hermes CLI — summarize meetings, inspect pipeline status, replay jobs, manage Microsoft Graph subscriptions.
systematic-debugging
4-phase root cause debugging: understand bugs before fixing.