mirror of
https://github.com/mermaid-js/mermaid.git
synced 2025-01-14 06:43:25 +08:00
Update packages/mermaid/src/docs.mts
Co-authored-by: Alois Klink <alois@aloisklink.com>
This commit is contained in:
parent
d3de78ffce
commit
d03fdfdbca
@ -67,7 +67,9 @@ const prettierConfig: prettier.Config = {
|
||||
let filesWereTransformed = false;
|
||||
|
||||
const generateHeader = (file: string): string => {
|
||||
return `# THIS IS AN AUTOGENERATED FILE. DO NOT EDIT. Please edit the source file in [${file}](../${file}).`;
|
||||
// path from file in docs/* to repo root, e.g ../ or ../../ */
|
||||
const rootDirectory = relative(file, "packages/mermaid/src/docs");
|
||||
return `# THIS IS AN AUTOGENERATED FILE. DO NOT EDIT. Please edit the source file in [${file}](${join(rootDirectory, file)}).`;
|
||||
};
|
||||
|
||||
/**
|
||||
|
Loading…
x
Reference in New Issue
Block a user