Expand description
A simple component that reactively renders an icon.
To render icons, this crate needs to be coupled with icondata,
which is an icon source providing over 20,000 icons.
§Getting Started
In your Cargo.toml, include both leptos_icons and icondata:
[dependencies]
leptos_icons = { version = "{crate_version}" }
icondata = { version = "{icondata_version}" }In your leptos project, use:
use leptos::prelude::*;
use leptos_icons::Icon;
let _ = view! {
<Icon icon=icondata::BsFolder />
};Complete examples are available on github.
Structs§
- Icon
Props - Props for the
Iconcomponent. - Symbol
Props - Props for the
Symbolcomponent.