Home

Awesome

<img src="./meta/phosphor-mark-tight-yellow.png" width="128" align="right" />

phosphor-leptos

crates.io docs.rs

Phosphor is a flexible icon family for interfaces, diagrams, presentations — whatever, really. You can explore the available icons at phosphoricons.com.

Installation

phosphor-leptos = "0.7.0"

or

cargo add phosphor-leptos

Usage

use leptos::prelude::*;
use phosphor_leptos::{Icon, IconWeight, HORSE, HEART, CUBE};

#[component]
fn MyComponent() -> impl IntoView {
    view! {
        <Icon icon=HORSE />
        <Icon icon=HEART color="#AE2983" weight=IconWeight::Fill size="32px" />
        <Icon icon=CUBE color="teal" weight=IconWeight::Duotone />
    }
}

Props

All of the props are Signals so they can be static or reactive.

License

MIT © Phosphor Icons

Knowledge

Contributing

To generate all the icons, run

cargo xtask update