mirror of
https://github.com/nunocoracao/blowfish.git
synced 2026-11-08 20:19:21 +00:00
Merge pull request #1461 from mnjm/code-importer-shortcode
✨ codeimporter shortcode
This commit is contained in:
2 files changed
+33
No files matched your search
@@ -0,0 +1,8 @@
|
||||
{{ $url := .Get "url" }}
|
||||
{{ $type := .Get "type" }}
|
||||
{{ with resources.GetRemote (printf $url) }}
|
||||
{{ $codeBlock := printf "```%s\n%s\n```" $type .Content }}
|
||||
{{ $codeBlock | markdownify }}
|
||||
{{ else }}
|
||||
{{ errorf "Code Importer Shortcode - Unable to get remote resource" . }}
|
||||
{{ end }}
|
||||
Reference in new issue
Block a user