API Reference

Sources

The config shapes register accepts.

SVG · { resolver }

OptionType
resolver(name, variant?) => string | { default: string } | Promise<…> - markup, URL or module
mutator(svg: SVGSVGElement) => void

Cached per name and variant. Output <span class="icon-svg">.

Font · { className }

OptionType
classNamestring
mappingRecord<string, string> | (name, variant?) => string | undefined
glyphsRecord<string, string> | (name, variant?) => string | undefined

Glyph values: hex codepoint (e001), a character, or a ligature name. Output <i class="…">glyph</i>.

Your own · { resolveSync?, resolve?, dispose? }

Stored as is. Wrap in cached() for the SVG library's caching. See Your own source.

munsonlabs · MIT licensed · © 2026