Document font substitution, measured.
docfonts publishes @docfonts/fallbacks, a small runtime package for document renderers.
It maps common proprietary document fonts to reviewed open-font fallback decisions.
The package ships no font binaries and no proprietary data. It contains a public evidence snapshot, asset-aware lookup helpers, and tests that prove the npm package only includes supported runtime files.
Built by the team behind SuperDoc. Standalone and neutral.
packages/fallbacks- runtime fallback decisions and lookup helpers.
getRenderableFallback- returns the open family to render, ornullwhen none is renderable.getFallbackDecision- explains the outcome for UI, diagnostics, and reporting.createFallbackMap- builds a resolver map from only the font families you can render.normalizeFamilyName- normalizes map lookup keys.
npm install @docfonts/fallbacksbun install
bun run typecheck
bun run test
bun run lint
bun run build@docfonts/fallbacks is released by the release-fallbacks workflow on every push to main.
semantic-release publishes a new version when the merged commits contain a releasable Conventional Commit.
The same workflow can still run manually as a dry run.