nicolaefilat
nicolaefilat3w ago

I am really struggling to get Deno and a decent ORM to work.

I tried prisma multiple times by following https://www.prisma.io/docs/orm/prisma-client/deployment/edge/deploy-to-deno-deploy and https://docs.deno.com/runtime/tutorials/how_to_with_npm/prisma/ but I always get an error about the database url not starting with prisma:// I looked at denoDB but that is not mentained now. What are my options to use and connect to a sqlite db using an ORM? Thanks
Deploy to Deno Deploy | Prisma Documentation
Learn how to deploy a TypeScript application to Deno Deploy.
4 Replies
frotstar
frotstar3w ago
Hi! So after struggling for ages, I found a solution, but it seems pretty hacky and I'm not sure if it's going to add more problems. If you check out this repo and read the instructions and the actions in the deno.json to see how it uses the patch.ts file and then check out the main test file to see how it imports and uses the client.ts, I've jkust gotten it to work. https://github.com/chrisabrams/deno-with-prisma/tree/master
GitHub
GitHub - chrisabrams/deno-with-prisma: An example of how to use Pri...
An example of how to use Prisma with Deno. Contribute to chrisabrams/deno-with-prisma development by creating an account on GitHub.
frotstar
frotstar3w ago
Though I feel like I'm having issues with it correctly populating the types and fields./
nicolaefilat
nicolaefilatOP3w ago
Hi! Thanks for letting me know about this. I ended up using mongoose as I do not really mind being stuck with mongodb.
akashpatil7596
Try TypeORM