Discover and display API entities for your components in Backstage
Install the plugin into Backstage.
yarn add @backstage/plugin-api-docs
Add plugin to the list of plugins.
// packages/app/src/plugins.ts
export { plugin as ApiDocs } from '@backstage/plugin-api-docs';
Add plugin API to your Backstage instance.
// packages/app/src/components/catalog/EntityPage.tsx
import { Router as ApiDocsRouter } from '@backstage/plugin-api-docs';
const ServiceEntityPage = ({ entity }: { entity: Entity }) => (
<EntityPageLayout>
...
<EntityPageLayout.Content
path="/docs/*"
title="Docs"
element={<DocsRouter entity={entity} />}
/>
...
</EntityPageLayout>
);
All other formats are displayed as plain text right now, but it could be easily extended.
To get the latest news, deep dives into Backstage features, and a roundup of recent open-source action, sign up for Roadie's Backstage Weekly. See recent editions.