Feat: add gist shortcode embed in theme

The gist shortcode was deprecated in hugo v0.143.0
This commit is contained in:
Cell
2025-04-02 16:11:55 +08:00
parent e2afa113be
commit 2b936cb6ad
2 changed files with 3 additions and 1 deletions
+1 -1
View File
@@ -1,4 +1,4 @@
{{- .Scratch.Set "version" "v0.3.17-8212d6fd" -}}
{{- .Scratch.Set "version" "v0.3.17-e2afa113" -}}
{{- .Scratch.Set "this" dict -}}
{{- partial "init/detection-env.html" . -}}
+2
View File
@@ -0,0 +1,2 @@
<script src="https://gist.github.com/{{ index .Params 0 }}/{{ index .Params 1 }}.js{{if len .Params | eq 3 }}?file={{ index .Params 2 }}{{end}}"></script>
{{- /* EOF */ -}}