Use api-docs to generate a link to a package's API documentation.
Use this transform only for a published Fluid Framework package that has API documentation on fluidframework.com.
The transform reads the package name from package.json. For a scoped package, it removes the scope from the documentation path.
| Option | Type | Default | Description | Notes |
|---|---|---|---|---|
packageJsonPath |
string | ./package.json |
Package file path relative to the destination document. | None. |
includeHeading |
boolean | true |
Include the API Documentation heading. |
When enabled, the transform determines the depth from the marker position. See Generated headings. |
headingLevel |
integer | Inferred | Set the context heading level from 1 through 6. | This value overrides the depth inferred from the marker position. |
The following marker generates API documentation without a heading:
<!-- markdown-magic:begin {"transform":"api-docs","includeHeading":false} -->
<!-- markdown-magic:end -->For an MDX document, use MDX comments:
{/* markdown-magic:begin {"transform":"api-docs","includeHeading":false} */}
{/* markdown-magic:end */}