@earendil-works/elanor-fonts

中文文档
0.1.0发布于 2026/11/05OFL-1.1ES Module零依赖近 30 天下载 1.2万

Mallos Serif, Commit Mono, and DepartureMono fonts with self-hosted CSS entry points.

原始使用文档

@earendil-works/elanor-fonts

Self-hosted Mallos Serif, Commit Mono, and DepartureMono fonts with @font-face CSS.

npm install @earendil-works/elanor-fonts

Import once at the application entry:

import '@earendil-works/elanor-fonts/mallos-serif.css';
import '@earendil-works/elanor-fonts/commit-mono.css';
ExportCSS familyWeightsStyles
mallos-serif.cssMallos Serif400–700normal, italic
commit-mono.cssCommit Mono300, 400, 700normal
departure-mono.cssDepartureMono400normal

Mallos Serif is a variable font: one file per style covers every weight from 400 to 700 (source).

DepartureMono is the Lefos mono font. Import it only in apps that use the Lefos tokens. It has one weight, so browsers synthesize bold.

CSS uses relative URLs and font-display: swap. Without a bundler, serve the CSS and files/ directory together.

For preloading or custom CSS, import @earendil-works/elanor-fonts/files/<filename>. Commit Mono also ships its original .otf files for desktop installs; the CSS uses WOFF2.

All families use SIL OFL 1.1. Include the matching file from licenses/ when redistributing them.

版本与发布记录

@earendil-works/elanor-fonts 共发布 2 个版本,首次发布于 2026/11/05;过去 12 个月发布了 2 个版本。

版本发布日期距今
0.1.0latest2026/11/058 天前
0.0.0-stage2026/11/058 天前

关于 @earendil-works/elanor-fonts 的常见问题

@earendil-works/elanor-fonts 是什么?

Mallos Serif, Commit Mono, and DepartureMono fonts with self-hosted CSS entry points.

如何安装 @earendil-works/elanor-fonts?

在项目目录运行 npm install @earendil-works/elanor-fonts,或使用 pnpm add / yarn add / bun add。

@earendil-works/elanor-fonts 支持 TypeScript 吗?

该包的 package.json 没有声明类型入口。需要类型提示时,可以在 npm 上查找社区维护的 @types/earendil-works__elanor-fonts 是否存在。

@earendil-works/elanor-fonts 支持 ESM 还是 CommonJS?

以 ES Module 形式发布,推荐使用 import 引入。在 CommonJS 项目中,Node.js 20.19+ / 22.12+ 可以直接 require() 不含顶层 await 的 ES Module,更早的版本需要改用动态 import()。

@earendil-works/elanor-fonts 可以商用吗?

@earendil-works/elanor-fonts 使用 OFL-1.1 许可。声明的许可为 OFL-1.1,请阅读许可原文确认使用条件。以上为概括,不构成法律意见,请以许可原文为准。

@earendil-works/elanor-fonts 的下载量有多少?

根据 npm 官方下载统计,@earendil-works/elanor-fonts 在 2026/10/13 – 2026/11/11 这 30 天内被下载 11,577 次,日均约 386 次。下载量会把 CI 构建、镜像同步和作为其他包依赖的安装一并计入,适合横向比较热度,不能直接等同于使用人数。

@earendil-works/elanor-fonts 还在维护吗?

最新版本 0.1.0 发布于 2026/11/05(8 天前);至今共发布 2 个版本,其中过去 12 个月发布了 2 个;首次发布于 2026/11/05。发布频率只是参考信号:功能稳定的工具可能很少需要更新,建议结合源码仓库的 issue 和提交记录判断。