Skip to main content

@backstage/plugin-techdocs-node

Home > @backstage/plugin-techdocs-node

Common functionalities for TechDocs, to be shared between techdocs-backend plugin and techdocs-cli

Classes

ClassDescription
DirectoryPreparerPreparer used to retrieve documentation files from a local directory
GeneratorsCollection of docs generators
PreparersCollection of docs preparers (dir and url)
PublisherFactory class to create a TechDocs publisher based on defined publisher type in app config. Uses techdocs.publisher.type.
TechdocsGeneratorGenerates documentation files
UrlPreparerPreparer used to retrieve documentation files from a remote repository

Interfaces

InterfaceDescription
DocsBuildStrategyA strategy for when to build TechDocs locally, and when to skip building TechDocs (allowing for an external build)
PublisherBaseBase class for a TechDocs publisher (e.g. Local, Google GCS Bucket, AWS S3, etc.) The publisher handles publishing of the generated static files after the prepare and generate steps of TechDocs. It also provides APIs to communicate with the storage service.
TechdocsBuildsExtensionPointExtension point type for configuring Techdocs builds.
TechDocsDocumentTechDocs indexable document interface
TechdocsGeneratorExtensionPointExtension point type for configuring a custom Techdocs generator
TechdocsPreparerExtensionPointExtension point type for configuring a custom Techdocs preparer

Variables

VariableDescription
getDocFilesFromRepositoryReturns a preparer response PreparerResponse
getLocationForEntityReturns a entity reference based on the TechDocs annotation type
getMkdocsYmlFinds and loads the contents of an mkdocs.yml, mkdocs.yaml file, a file with a specified name or an ad-hoc created file with minimal config.
getMkDocsYml
parseReferenceAnnotationReturns a parset locations annotation
techdocsBuildsExtensionPointExtension point for configuring Techdocs builds.
techdocsGeneratorExtensionPointExtension point for configuring a custom Techdocs generator
techdocsPreparerExtensionPointExtension point for configuring a custom Techdocs preparer
transformDirLocationTechDocs references of type dir are relative the source location of the entity. This function transforms relative references to absolute ones, based on the location the entity was ingested from. If the entity was registered by a url location, it returns a url location with a resolved target that points to the targeted subfolder. If the entity was registered by a file location, it returns an absolute dir location.

Type Aliases

Type AliasDescription
ETagA unique identifier of the tree blob, usually the commit SHA or etag from the target.
GeneratorBaseGenerates documentation files
GeneratorBuilderThe generator builder holds the generator ready for run time
GeneratorOptionsOptions for building generators
GeneratorRunOptionsThe values that the generator will receive.
MigrateRequestTechDocs entity triplet migration request
ParsedLocationAnnotationParsed location annotation
PreparerBaseDefinition of a TechDocs preparer
PreparerBuilderDefinition for a TechDocs preparer builder
PreparerConfigOptions for building preparers
PreparerOptionsOptions for configuring the content preparation process.
PreparerResponseResult of the preparation step.
PublisherFactoryOptions for building publishers
PublisherTypeKey for all the different types of TechDocs publishers that are supported.
PublishRequestRequest publish definition
PublishResponseResponse containing metadata about where files were published and what may have been published or updated.
ReadinessResponseResult for the validation check.
RemoteProtocolLocation where documentation files are stored
SupportedGeneratorKeyList of supported generator options
TechDocsMetadataType to hold metadata found in techdocs_metadata.json and associated with each site