Skip to Content
Referencefusion-uiUtilitiesextendIcon

extendIcon

A utility function for adding custom icon definitions to an Icon component.

Usage

import { Icon, createIcon, extendIcon } from "@codedazur/fusion-ui"; import someIcon from "./some-icon.svg"; import anotherIcon from "./another-icon.svg"; const ExtendedIcon = extendIcon(Icon, { SomeIcon: createIcon(someIcon), AnotherIcon: createIcon(anotherIcon), }); function MyComponent() { return ( <div> <ExtendedIcon.SomeIcon /> <ExtendedIcon.AnotherIcon /> </div> ); }
Last updated on