Merge pull request #15257 from backstage/jhaals/quote-docs

repo-tools: Quote markdown headers in api-docs
This commit is contained in:
Johan Haals
2022-12-15 16:39:29 +01:00
committed by GitHub
2 changed files with 8 additions and 1 deletions
+5
View File
@@ -0,0 +1,5 @@
---
'@backstage/repo-tools': patch
---
Updated api docs generation to be compatible with Docusaurus 2-alpha and 2.x.
@@ -840,7 +840,9 @@ export async function buildDocs({
context.writer.writeLine('---');
for (const [name, value] of Object.entries(node.values)) {
if (value) {
context.writer.writeLine(`${name}: ${value}`);
context.writer.writeLine(
`${name}: "${String(value).replace(/\"/g, '')}"`,
);
}
}
context.writer.writeLine('---');