agentleFS
PawelBednarekPunksPawelBednarekPunks/aidevbird-skills/skills/angular-conventions/SKILL.md

angular-conventions

Skill1 starsChanged 7 days agoMITView on GitHub

Modern Angular (v18+) coding standards — signals, standalone, OnPush, inject(), built-in control flow. Use when writing, refactoring or reviewing Angular code.

The file

We split this skill into the rules it gives an agent

4 rules. About 0 are common, 0 are distinctive, and 4 are very specific to this project.

  • ≈0

    Common · estimate

    Many files like this have a rule of this kind.

  • ≈0

    Distinctive · estimate

    This author's own choices. Worth a look.

  • 4

    Very specific

    Tied to their project's names, files or tools. Probably skip.

  • Common
  • Distinctive
  • Very specific
  1. Very specific:

    Import only the pipes/directives used, never CommonModule.

    line 12
  2. Very specific:

    Update with set/update returning new objects/arrays — never mutate.

    line 19
  3. Very specific:

    No method calls in bindings ({{ total() }} of a computed is fine, {{ calcTotal() }} is not) — use computed() or a pure pipe.

    line 28
  4. Very specific:

    No silent catchError(() => of(null)) — log and expose an error state.

    line 33

≈ “Common” is an estimate: at least 1 in 5 of the 350,495 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.

Keep what fits and drop the rest. Your version, ready for your agents.
Files
SKILL.md

Angular Conventions

Project rules (lint config, existing patterns) override these.

Components:

  • Standalone (default since v19 — don't write standalone: true). Always ChangeDetectionStrategy.OnPush.
  • Import only the pipes/directives used, never CommonModule.
  • Host bindings in host: {} metadata, not @HostBinding/@HostListener.
  • Template-only members protected; internals #private.

Signals:

  • input(), input.required(), output(), model() — no @Input/@Output, no Signal suffix, no aliases.
  • State signal(), derived computed(), writable derived linkedSignal().
  • Update with set/update returning new objects/arrays — never mutate.
  • effect() only for real side effects (DOM libs, analytics), never to copy state between signals.

DI:

  • readonly #api: ApiService = inject(ApiService); — empty or no constructor.
  • Stateless services providedIn: 'root'; config through typed InjectionToken<T>.

Templates:

  • @if, @for, @switch only. Every @for has track item.id ($index only for primitives); add @empty where a list can be empty.
  • No method calls in bindings ({{ total() }} of a computed is fine, {{ calcTotal() }} is not) — use computed() or a pure pipe.
  • [class.x]/[style.x] instead of ngClass/ngStyle.

Types and errors:

  • No any. External data is unknown, narrowed by a type guard or schema (Zod/Valibot).
  • No silent catchError(() => of(null)) — log and expose an error state. No console.log.
@Component({
  selector: 'app-user-card',
  templateUrl: './user-card.component.html',
  changeDetection: ChangeDetectionStrategy.OnPush,
  host: { '[class.active]': 'active()', '(click)': 'select.emit(user().id)' },
})
export class UserCardComponent {
  readonly user = input.required<User>();
  readonly active = input(false);
  readonly select = output<string>();
  readonly #format: NameFormatter = inject(NameFormatter);
  protected readonly name = computed(() => this.#format.full(this.user()));
}

Tests: *.spec.ts next to the file; test inputs, outputs and user interaction, not private details.

Download now (ZIP)

Does it work?

Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.

No reviews yet

People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.

  • It worked
  • Partly
  • It didn't
What did you use it for? e.g. Reviewing pull requests in a Rails app

Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.

Your trail

Files you open will collect here, so you can find them again.

Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.

Now do this for your own.

Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.