diff options
| author | Eltrac <hi@guhub.cn> | 2025-08-02 09:27:40 +0800 |
|---|---|---|
| committer | Eltrac <hi@guhub.cn> | 2025-08-02 09:27:40 +0800 |
| commit | af09283e00095924f0413dc229c6fffc43412676 (patch) | |
| tree | 2c84db4e66e639b6dc40d9e4dece3227cbb9cad2 /layouts/_partials/scripts.html | |
| parent | 04112af732137f2a93452f618347de9908ca9de1 (diff) | |
perf: refactor render-blocking action-menu logic
- put initialization script at the end of the page
- delay initialization furthermore
- delay comment count fetch after giscus iframe is loaded
Former-commit-id: ea845e50495d79f48315c281186a51aa486ae263
Diffstat (limited to 'layouts/_partials/scripts.html')
| -rw-r--r-- | layouts/_partials/scripts.html | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/layouts/_partials/scripts.html b/layouts/_partials/scripts.html index 6dc0080b..7c000323 100644 --- a/layouts/_partials/scripts.html +++ b/layouts/_partials/scripts.html @@ -7,6 +7,10 @@ {{ partial "scripts/fancybox-js" . }} {{ partial "scripts/aplayer-js" . }} +{{ if .File }} + {{ partial "scripts/action-menu-js" (.File.UniqueID | urlize) }} +{{ end }} + {{ with resources.Get "js/tooltip.js" }} <script>{{ .Content | safeJS }}</script> {{ end }} |
