The essenfont package is a thin shell: it exposes the canonical OTC path on disk, build-time metadata (version, donor count, character count, sha256), and a TypeScript-typed surface for build pipelines that need to know which file to embed.
Imports
import { path, metadata } from "essenfont";
// path → absolute path to the OTC on disk
// metadata → { version, donorCount, charCount, sha256, ... }
Metadata
| Field | Type | Notes |
|---|---|---|
version |
string |
Semver string from the source repo |
donorCount |
number |
Count of OFL-licensed donor fonts |
charCount |
number |
Assigned Unicode 17 codepoints covered |
sha256 |
string |
OTC binary digest (integrity check) |
Using the font binary in a build
import { path } from "essenfont";
import { readFileSync } from "node:fs";
// Use with fontTools, fontisan, or any SFNT parser
const otcBytes = readFileSync(path);
Build pipeline reference
The full build is a Ruby pipeline in the essenfont/essenfont repo:
# Donor registry → CpMap → Stitcher → OTC
const cpMap = Essenfont::CpMap.from_donors(donors)
const stitcher = Fontisan::Stitcher.new
# ... (see the essenfont repo for the full pipeline)
See Build pipeline for the full architecture.