@molecule/app-fonts-material-symbols
Provider bond · fonts · App (browser) · v1.1.0 · Apache-2.0
Material Symbols Outlined — local, self-hosted font (no external CDN)
npm install @molecule/app-fonts-material-symbolsnpm · Source on GitHub · Implements @molecule/app-fonts
How it works
@molecule/app-fonts-material-symbols is a provider bond on the app (browser) side: it implements the fonts core interface (@molecule/app-fonts) with a concrete vendor or library behind it.
Your code calls the core; you wire this provider once at startup. Swapping vendors later is one line in that wiring, not a rewrite.
import { setFont } from '@molecule/app-fonts'
import { font as icons } from '@molecule/app-fonts-material-symbols'
setFont(icons) // once, at app startup — before first paintWorks with: @molecule/app-fonts
Reference
Material Symbols Outlined font for molecule.dev.
Auto-generated, AI-first package reference for the molecule.dev ecosystem. It is written to be read by coding agents as much as by people, and is generated from this package's source — edit
src/index.tsJSDoc, not this file.
Quick Start
import { setFont } from '@molecule/app-fonts'
import { font as icons } from '@molecule/app-fonts-material-symbols'
setFont(icons) // once, at app startup — before first paint
Glyphs render through the .material-symbols-outlined utility class
(injected by setFont() with the @font-face), using ligature names:
<span class="material-symbols-outlined">home</span>
Type
provider
Installation
npm install @molecule/app-fonts-material-symbols @molecule/app-fonts
API
Functions
glyphCodepoint(name)
The codepoint that draws a Material Symbols glyph name.
function glyphCodepoint(name: string): number | undefined
name— The glyph name (check_circle).
Returns: The codepoint, or undefined for a name the font does not draw.
Constants
FILLED_FAMILY
The family of the filled static instance (fonts/MaterialSymbolsOutlined-Filled.ttf).
const FILLED_FAMILY: 'Material Symbols Outlined Filled'
glyphs
Material Symbols' glyphs, for FontDefinition.glyphs.
const glyphs: FontGlyphs
font
Material Symbols Outlined font definition — local, self-hosted (no external CDN). A browser draws
each glyph from its ligature name, so this definition carries no glyph table; React Native takes
nativeFont from ./native, which does.
const font: FontDefinition
Core Interface
Implements @molecule/app-fonts interface.
Injection Notes
Requirements
Peer dependencies:
@molecule/app-fonts^1.4.0
Runtime Dependencies
-
@molecule/app-fonts -
Browser wiring: import
fontfrom this package and callsetFont(font)at startup. The packaged faces resolve relative to this module; the browser bundler emits the complete files as fingerprinted assets, including its configured public base path. No manual copy or app-side asset import is needed. -
The registry retains filenames for
mlclstatic font copying. A custom face may still use a plain filename withsetFont'sbasePathoption.