Skip to content

pantoken-root / packages/core/src / getIconSvgs

Feidhm: getIconSvgs() ​

getIconSvgs(tokens): Map<string, string>

Béite

Mapaigh gach token íocóin chuig a SVG díchódaithe (eochairithe de réir ainm gan an réamhfhocal --instui-icon-).

Paraiméadair ​

tokens ​

inléite Token[]

Tuairisceáin ​

Map<string, string>

Sampla ​

ts
import { buildTokens } from "@pantoken/core/build";
import { getIconSvgs } from "@pantoken/core";

const svgs = getIconSvgs(buildTokens());
svgs.get("arrow-left"); // → inline SVG markup for the arrow-left glyph (non-icon tokens skipped)