leptos_heroicons

Crates.ioleptos_heroicons
lib.rsleptos_heroicons
version0.1.1
sourcesrc
created_at2023-07-17 02:04:00.55724
updated_at2023-07-17 02:26:14.001763
descriptionHeroicons for Leptos
homepage
repositoryhttps://github.com/bbstilson/leptos_heroicons
max_upload_size
id918092
size832,157
Brandon Stilson (bbstilson)

documentation

README

Leptos Heroicons

Heroicons Components for Leptos

Usage

For each icon you want to use, you'll need to add a feature flag for those components. Only the icons you specify will be compiled into your application.

leptos_heroicons = { version = "0.1.0", features = [
    "24-solid-power",
    "24-outline-wrench",
    "20-solid-credit-card"
]}

You can also include all the icons of a given type by specifying the size-type feature:

leptos_heroicons = { version = "0.1.0", features = [
    "24-solid",
    "24-outline",
    "20-solid"
]}

In your leptos app:

use leptos::*;
use leptos_heroicons::size_24::solid::Power;

#[component]
fn UnlimitedPower(cx: Scope) -> impl IntoView {
    view! { cx,
        <Power />
    }
}

Inspiration / Credit

Commit count: 11

cargo fmt