Is it feasible to use prisma client in the browser against sqlite compiled to webassembly #18428
-
Hello. My project uses Prisma with sqlite on the backend already, and we're quite happy with it. I'm now working on implementing offline support in our client, and it occurred to me that it'd be great to be able to reuse some of our schema between the client and the server (or at least get to use some of prisma's awesome features in both places if schema can't be shared). I'm looking for a sanity check that this is even possible today, and if it is, guidance on where to start. I see that the official sqlite project has support for running in the browser with webassembly and storage provided by localstorage. We've already got a monorepo set up that allows us to share JS code successfully between the client and server. If this idea isn't possible today, perhaps this post can be a place of discussion for what it might take to make it possible in the future, and whether the project is interested in doing so. |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 2 replies
-
Prisma currently can not do that, as we do not compile the full engines to Wasm. |
Beta Was this translation helpful? Give feedback.
Prisma currently can not do that, as we do not compile the full engines to Wasm.
Attempting this is also not a priority right now, as we are quite busy with Node as a environment - we won't add browser to our workload here at least this year.