Nextjs pages router: You may need an appropriate loader to handle this file type
next: 14.2.15
drizzle: 0.35.3
libsql/client: 0.14.0
To get PDF rendering working, it was suggested to me that I move a route from app router to pages router. Everything checks out on the type level, but I'm getting this error in runtime:
I saw this issue: https://github.com/drizzle-team/drizzle-orm/issues/3155
Switched all my Turso stuff over to using /web but it still happens. Just tried making a minimal repro but it seems to work fine.
I'm not familiar with pages router at all, as I started using React/Next with app router. All I know is that this is a webpack thing, I just have no idea why it would error on a column with a type set on it..
GitHub
[BUG]: Drizzle orm + libsql (turso) does not build with NextJS · Is...
What version of drizzle-orm are you using? 0.35.2 What version of drizzle-kit are you using? 0.26.2 Describe the Bug I'm trying to upgrade to latest drizzle openstatusHQ/openstatus#1048 But Bui...
Solution:Jump to solution
for anyone else running into this: needed to add
transpilePackages: ["@repo/schema"]
to my next config.1 Reply
Solution
for anyone else running into this: needed to add
transpilePackages: ["@repo/schema"]
to my next config.