Is there any examples of making a library with vite that exports a Solid.js Component.
I want to make one.
5 Replies
https://github.com/solidjs-community/solid-lib-starter is pretty great
GitHub
GitHub - solidjs-community/solid-lib-starter: SolidJS library start...
SolidJS library starter template. Use it to create your own solid package. - solidjs-community/solid-lib-starter
it uses tsup for bundling and vite as the dev server for an example page.
@bigmistqke - do you know how to export my .css files with this package?
I see that it's present in the dist directory, but when I installed my library inot another project, it's not applying styles.
So I did an import
library/dist/index.css
but vite says specifiier not foundA ye, I remember having to deal w that too.
I think I eventually went for vite library mode then bc I also needed some other vite niceties. But mb https://github.com/egoist/tsup/issues/536 can help
GitHub
[Wanted] Support CSS module · Issue #536 · egoist/tsup
Upvote & Fund We're using Polar.sh so you can upvote and help fund this issue. We receive the funding once the issue is completed & confirmed by you. Thank you in advance for helping pr...