mzlogin.github.io
mzlogin.github.io copied to clipboard
压缩 HTML,进一步提升加载速度,参考
https://zhang0peter.com/2020/01/27/jekyll-inline-css/ https://mayanbin.com/post/compress-html-in-jekyll.html http://jch.penibelst.de/
压缩 HTML 过程中出现过两种问题:
Uncaught SyntaxError: Unexpected end of input
原因是内嵌 js 里有 // 注释
Uncaught SyntaxError: Unexpected identifier
原因是内嵌 js 里表达式没用 ; 结尾,压缩后报错
可以考虑将搜索使用的 json,通过 ci 推到别的分支,然后通过 jsdelivr 引用。