Skip to content

Latest commit

 

History

History
 
 

api-extractor

Folders and files

NameName
Last commit message
Last commit date

parent directory

..
 
 
 
 

Configuration - API Extractor

license: Cisco state: beta scope: internal

The contents of this folder are used as a shared collection of scripts and files when applying a standard API Extractor Documentation ruleset to modern and legacy modules within this project.

Installation

This package is meant to be consumed as a relative link, and requires the following dev-dependencies:

  • @microsoft/api-extractor
  • @microsoft/api-documenter

Installation of the required dependencies, local to this project, can be performed by using the following commands:

yarn workspace @{scope}/{package} add --dev @microsoft/api-extractor @microsoft/api-documenter

Usage

This package is expected to be used with API Extractor.

An api-extractor.config.json configuration file must be consumed within the target package using the following configuration definition example:

// ./api-extractor.config.json

{
  "extends": "./../../../config/api-extractor/index.json",
  "projectFolder": "."
}

This will target all built *.d.ts files within the ./dist/types/** folder, and generate output files within the ./dist/docs/metadata/** folder.

This package is recommended to be used along side the @microsoft/api-documenter package by introducing the following script to the packages ./package.json file.

{
  "scripts": {
    "build": "{...other build commands...} && yarn build:docs",
    "build:docs": "{...other documentation build commands...} && yarn build:docs:api",
    "build:docs:api": "yarn build:docs:api:metadata && yarn build:docs:api:markdown",
    "build:docs:api:metadata": "api-extractor run -c ./api-extractor.config.json",
    "build:docs:api:markdown": "api-documenter markdown --input-folder ./docs/api/metadata --output-folder ./docs/api/markdown",
  }
}

Contribute

Pull requests welcome. Please see CONTRIBUTING.md for more details.

Maintainers

This package is maintained by Cisco Webex for Developers.