templUI Pro coming soon  

50% OFF Join Waitlist

Icon

A wrapper for Lucide Icons with optional settings for size, color, fill, stroke, and custom classes. Browse available icons in the Lucide library to see what you can use.

Source
TailwindCSS

Installation

templui add icon

Examples

Colored

Filled

Sizes

API Reference

Required parameter
Hover for description

Icon

Wrapper component for Lucide Icons with customizable size, color, fill, and stroke properties.

Name Type Default
Name
IconName
-
ID
string
-
Class
string
-
Attributes
templ.Attributes
-
Size
int
24
Color
string
currentColor
Fill
string
none
StrokeWidth
float64
2