Skip to content

Commit d3d20ad

Browse files
committed
Vendor mermaid ourselves instead of using jsdelivr
1 parent 099bb74 commit d3d20ad

4 files changed

Lines changed: 4 additions & 20 deletions

File tree

docs/.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
# build output
22
dist/
33
public/slides/
4+
public/js/
45
# generated types
56
.astro/
67

docs/package-lock.json

Lines changed: 1 addition & 18 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

docs/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
"start": "astro dev",
88
"prebuild": "npm run generate-agent-factory && npm run build:slides",
99
"build": "astro build",
10-
"build:slides": "npx @marp-team/marp-cli slides/index.md --html --allow-local-files -o public/slides/index.html",
10+
"build:slides": "mkdir -p public/js && cp node_modules/mermaid/dist/mermaid.esm.min.mjs public/js/ && npx @marp-team/marp-cli slides/index.md --html --allow-local-files -o public/slides/index.html",
1111
"preview": "astro preview",
1212
"astro": "astro",
1313
"validate-links": "astro build",

docs/slides/index.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ marp: true
33
---
44

55
<script type="module">
6-
import mermaid from 'https://cdn.jsdelivr.net/npm/mermaid@11.12.2/dist/mermaid.esm.min.mjs';
6+
import mermaid from '/gh-aw/js/mermaid.esm.min.mjs';
77
mermaid.initialize({ startOnLoad: true });
88
</script>
99

0 commit comments

Comments
 (0)