What to put in an AGENTS.md for Angular
Agents learned Angular from NgModules, zone.js and *ngIf. Standalone is the default since v20, new apps are zoneless since v21, and new CLI projects test with Vitest; Angular publishes its own AI rules file to start from.
By Himanshu Singh · Updated · How we score →
Which commands should it list?
ng servedev serverng buildthe@angular/build:applicationbuilder by defaultng testVitest in new projects; Karma still supportedng generate component <name>orng g; scaffolds where the CLI expectsnpx @angular/cli mcpthe CLI's experimental MCP server
Write them as your repo runs them, with its package manager and flags, plus how to run one test.
What layout should it explain?
- The Angular major, and whether the app is zoneless or still loads zone.js.
- The test runner, Vitest or Karma, so tests use the right APIs.
- Which project in
angular.jsonis the app, and where feature folders and shared libraries live.
What do agents get wrong?
- Don't set
standalone: true; it is the default since v20. - Use
@if,@forand@switch, not*ngIf,*ngForand*ngSwitch. - Signals for state and
computed()for derived state. - Zoneless is the default since v21; don't rely on zone.js to trigger change detection.
From the official docs: angular.dev/develop-with-ai (new tab) · angular.dev/mcp (new tab) · angular.dev/zoneless (new tab) · angular.dev/testing (new tab) · angular.dev/generate (new tab) · angular.dev/releases (new tab). The rest of the file is the same for any project: what goes in an AGENTS.md.
Angular repos with an AGENTS.md or CLAUDE.md (4)
Built on Angular; 4 pass the AGENTS.md check in full.
| Repo | File | Length | Stars | Language | Score |
|---|---|---|---|---|---|
| bitwarden/ | .claude/CLAUDE.md | 3,393 chars | 14.3k ★ | TypeScript | 83.2 |
| NG-ZORRO/ | AGENTS.md | 2,263 chars | 9.2k ★ | TypeScript | 89.5 |
| taiga-family/ | AGENTS.md | 10,530 chars | 4.1k ★ | TypeScript | 83.2 |
| opf/ | AGENTS.md | 4,767 chars | 17.6k ★ | Ruby | 85.9 |
By language: TypeScript AGENTS.md examples
More examples: Next.js · React · FastAPI · Flutter · Android · .NET · Rails · Vue · Laravel · Django · React Native · Spring Boot · iOS · all examples