fontawesome-svgs
v2.0.0
Published
A tree-shakable library that exports fontawesome SVGs as strings.
Readme
FontAwesome SVGs
Introduction
A tree-shakable library that exports Font Awesome SVGs as strings.
Supported versions
- Font Awesome 5
- Font Awesome 6
Usage
Icons are exported as fa{version}_{iconSet}_{iconName}. For example:
import { fa5_solid_bell } from "fontawesome-svgs";
document.body.innerHTML = fa5_solid_bell;Apply default styles:
import "fontawesome-svgs/default.css";Apply line-box-centered styles:
import "fontawesome-svgs/centered.css";Manually apply styles:
svg.fa {
fill: currentColor;
height: 1em;
/* ... */
}Building
The library is generated using a Bun.js script.
To add your own icons, place them in the icons directory, then run the build script:
npm run buildLicense
Original license applies to Font Awesome icons. https://fontawesome.com/license/free
The rest of the library is MIT licensed.
