mirror of
https://github.com/2234839/web-font.git
synced 2026-09-04 23:02:27 +08:00
- 修改 interface.ts: 接受 options.unlink 和 options.rm 作为 FS 适配器的可配置方法 - 修改 llrt.ts: 使用箭头函数 (path) => fs.rm(path) 避免 this 绑定问题 - 修改 app.ts: 通过 __RUNTIME__ 条件编译,仅在 LLRT 运行时引入 llrt.ts - 修改 tsdown.config.ts: format 从字符串数组改为字符串类型,添加 as const - 修改 tsconfig.node.json: 添加 node 类型支持 - 新增 backend/global.d.ts: 声明 __RUNTIME__ 全局变量类型 - 修改 .gitignore: 添加 dist_backend_node 目录 - 修改 build-backend.ts: 支持 Node.js 版本构建输出到 dist_backend_node 修复问题: - LLRT fs/promises 没有 unlink 方法,只有 rm 方法 - CJS 格式不支持 top-level await,改用 IIFE + require - 条件编译避免 Node.js 版本包含不必要的 LLRT 适配代码