daicons
v0.0.3
Published
Dakik Studio icon library for React and Next.js
Maintainers
Readme
daicons
A bold, modern icon library from Dakik Studio for React and Next.js apps.
daicons ships 1,400+ SVG icons and loads each icon on demand, so your app only pulls what it uses.
Install
npm install daiconsQuick start
"use client";
import { DaIcon } from "daicons";
export function Hero() {
return <DaIcon label="Sparkle" name="sparkle-fill" size={24} />;
}Why daicons
- Clean, consistent visual language
- Fast dynamic loading per icon
- Type-safe icon names (
DaIconName) - Great fit for product UIs, dashboards, and marketing pages
API
DaIcon- React component that renders an icon by namegetIconSvg(name)- async function that returns a sanitized SVG stringpreloadIcon(name)- preload an icon before renderhasIcon(name)- check whether an icon name existsiconNames- list of all available icon namesDaIconName- union type of generated icon names
Preload example
"use client";
import { useEffect } from "react";
import { DaIcon, preloadIcon } from "daicons";
export function FeatureCard() {
useEffect(() => {
void preloadIcon("rocket-launch-fill");
}, []);
return <DaIcon label="Rocket launch" name="rocket-launch-fill" size={20} />;
}License
MIT
https://dakik.co.uk
https://dakik.co.uk/daicons
