Skip to content
New Read what changed in the latest release →

Documentation for Angular projects, generated from your code.

Write guides in Markdown with Nunjucks, get an API reference straight from your TypeScript, and drop live demos and playgrounds into any page, all inside a regular Angular app you control.

ng add @ng-doc/add
  • Open source, MIT
  • Angular CLI and Nx
  • SSR and static prerender
How a page is made

A folder, two files, one page

Each page is a folder with an ng-doc.page.ts and a Markdown file. NgDoc turns it into a routed Angular page with a table of contents, a search entry and links.

You write
index.md
# {{ NgDocPage.title }} A button is an interface element that allowsthe user to perform an action when clicked. {% include "../shared/import-note.md" %} {{ NgDocActions.demo("ButtonDemoComponent") }} Configure it with `ButtonComponent` inputs.
Readers get

Button

A button is an interface element that allows the user to perform an action when clicked.

Note

Component can be imported from the root of my-lib.

PrimarySoftOutline

Configure it with ButtonComponent inputs.

Get going in minutes

Three steps to your first page

NgDoc does not create a separate app: it generates pages into the Angular application you already have, so you can customise anything.

  1. Add NgDoc

    The schematic installs the packages and configures the builder for Angular CLI or Nx.

    ng add @ng-doc/add
  2. Create a page

    Add a folder with a page config and Markdown next to your code, or let NgDoc scan your API.

    docs/button/ ng-doc.page.ts index.md
  3. Serve and ship

    Run the dev server while you write, then build or prerender for any static host.

    ng serve ng build
API reference

An API reference that never drifts

Point NgDoc at your entry points; every exported declaration gets a page, grouped by package and kind.

  • Members, overloads, decorators and modifiers from TypeScript
  • JSDoc descriptions, @see links and deprecations
  • Scopes for multi-package workspaces
  • NgDocCodeComponentComponent
  • NgDocThemeServiceInjectable
  • NgDocSidebarComponentComponent
  • provideNgDocAppFunction
  • NgDocCustomNavbarDirectiveDirective
  • NgDocPageInterface
  • NgDocDefaultSearchEngineClass
  • NG_DOC_DEFAULT_PAGE_PROCESSORSVariable
Browse the API References →

Start documenting your library today

Install with one command, write your first page in Markdown, and ship a searchable docs site.