rmacfie
rmacfie
SSolidJS
Created by Hussein on 5/2/2024 in #support
how to use bun:sqlite without it leaking to the browser?
You may get some guidance from this example with Prisma: https://github.com/solidjs/solid-start/tree/main/examples/with-prisma Pay attention to how the const db is declared in one file (src/lib/db.ts) and the actions with "use server" are declared in another (src/lib/index.ts), and then the components that use them are in yet another file. This separation is necessary to enable complete treeshaking so that the code that you only want on the server does not leak to the client. I'm hoping there will be more thorough documentation on this, because I also find these things to be rather confusing.
12 replies
SSolidJS
Created by rmacfie on 1/18/2024 in #support
.env.local not working
I can't get anything to work other than putting everything in .env. I wonder if there's anything in solid-start or vinxi that influences this behavior? In a vanilla vite-app it works just as documented.
5 replies