Skip to content

How do I setup icon files to be imported by an index.js file #1187

Answered by shyakadavis
FranklinP44 asked this question in Help
Discussion options

You must be logged in to vote

Hey, @FranklinP44

It's really simple; they basically do this: https://github.com/huntabyte/shadcn-svelte/blob/main/apps/www/src/lib/components/docs/icons/index.ts

And then when using, you just do:

<Icons.close aria-hidden="true" class="size-5" />

Replies: 1 comment 4 replies

Comment options

You must be logged in to vote
4 replies
@FranklinP44
Comment options

@FranklinP44
Comment options

@shyakadavis
Comment options

@FranklinP44
Comment options

Answer selected by FranklinP44
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Help
Labels
None yet
2 participants