From a1ebb1c85ae6d749170ce4e9b18f0bdec92d27e8 Mon Sep 17 00:00:00 2001 From: ben Date: Sat, 28 Jun 2025 11:20:24 -0700 Subject: bare --- layouts/_partials/head/js.html | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) create mode 100644 layouts/_partials/head/js.html (limited to 'layouts/_partials/head/js.html') diff --git a/layouts/_partials/head/js.html b/layouts/_partials/head/js.html new file mode 100644 index 0000000..16ffbed --- /dev/null +++ b/layouts/_partials/head/js.html @@ -0,0 +1,16 @@ +{{- with resources.Get "js/main.js" }} + {{- $opts := dict + "minify" (not hugo.IsDevelopment) + "sourceMap" (cond hugo.IsDevelopment "external" "") + "targetPath" "js/main.js" + }} + {{- with . | js.Build $opts }} + {{- if hugo.IsDevelopment }} + + {{- else }} + {{- with . | fingerprint }} + + {{- end }} + {{- end }} + {{- end }} +{{- end }} -- cgit v1.2.3