支持 html sass 产物压缩 (#265)
All checks were successful
continuous-integration/drone/push Build is passing

This commit is contained in:
neveler 2025-10-04 09:32:45 +08:00 committed by GitHub
parent 3e25c316f5
commit 8c0f50460a
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
2 changed files with 41 additions and 0 deletions

View File

@ -117,9 +117,13 @@ permalink: /:categories/:title/
compress_html:
clippings: all
comments: all
ignore:
envs: development
sass:
style: compressed
head_scripts:
- /assets/js/theme.js

37
_layouts/default.html Normal file
View File

@ -0,0 +1,37 @@
---
layout: compress
---
<!doctype html>
{% include copyright.html %}
<html lang="{{ site.locale | replace: "_", "-" | default: "en" }}" class="no-js">
<head>
{% include head.html %}
{% include head/custom.html %}
</head>
<body class="layout--{{ page.layout | default: layout.layout }}{% if page.classes or layout.classes %}{{ page.classes | default: layout.classes | join: ' ' | prepend: ' ' }}{% endif %}" dir="{% if site.rtl %}rtl{% else %}ltr{% endif %}">
{% include_cached skip-links.html %}
{% include_cached masthead.html %}
<div class="initial-content">
{{ content }}
{% include after-content.html %}
</div>
{% if site.search == true %}
<div class="search-content">
{% include_cached search/search_form.html %}
</div>
{% endif %}
<div id="footer" class="page__footer">
<footer>
{% include footer/custom.html %}
{% include_cached footer.html %}
</footer>
</div>
{% include scripts.html %}
</body>
</html>