KonghaYao / cn-font-split

划时代的字体切割工具,CJK与任何字符!支持 otf、ttf、woff2 字体多线程切割,完美地细颗粒度地进行包大小控制。A revolutionary font subetter that supports CJK and any characters! It enables multi-threaded subset of otf, ttf, and woff2 fonts, allowing for precise control over package size.
https://chinese-font.netlify.app/
Apache License 2.0
442 stars 15 forks source link

【build】构建文件 hash 值不稳定问题 #75

Closed KonghaYao closed 1 month ago

KonghaYao commented 2 months ago

原因: @napi-rs/woff-build 虽然快,但是其使用的算法不稳定,会导致 ttf -> woff2 的压缩成果变得不一致。

KonghaYao commented 2 months ago

采用 ttf 文件的 hash 值作为文件名称,保证构建产物可以被 CDN 缓存