-
-
Notifications
You must be signed in to change notification settings - Fork 1
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[BUG]: Nextjs 15 can't find the index.mjs #41
Comments
Hi! I'm getting this error as well. I managed to fix it by installing drizzle-lab in my node_modules and editing the cli.js file directly. It looks like Lines 81 to 99 in fce9454
I wrote this (rather hack-y) way of getting the directory: Replaced this:
With:
Great work with the visualizer btw! |
Hum 🧐 let me guess, is it cjs and not esm? |
I'll look at that this evening. Did you try the vscode extension? |
I have installed a fresh nextjs 15 project and I can't reproduce. {
"name": "n15",
"version": "0.1.0",
"private": true,
"scripts": {
"dev": "next dev",
"build": "next build",
"start": "next start",
"lint": "next lint"
},
"dependencies": {
"drizzle-orm": "^0.36.4",
"next": "15.0.3",
"react": "19.0.0-rc-66855b96-20241106",
"react-dom": "19.0.0-rc-66855b96-20241106"
},
"devDependencies": {
"@types/node": "^20",
"@types/react": "^18",
"@types/react-dom": "^18",
"drizzle-kit": "^0.28.1",
"eslint": "^8",
"eslint-config-next": "15.0.3",
"postcss": "^8",
"tailwindcss": "^3.4.1",
"typescript": "^5"
},
"overrides": {
"drizzle-orm": {
"react": "$react"
}
}
} I wonder what is causing this issue. You are the second person to report it. |
If you could try with |
Hi @rphlmr, I think I cracked it: I'm running 20.9.0, which doesn't have it. Visualizer in VS code worked though! You might want to add a bit to the README on how to access it, took me a while to realize the button was in the drizzle.config.js. Debugging Info: Fresh environment (just Node, not NextJS):
Here's the debug info with a few things redacted, though it looked all normal:
package.json:
|
WOW thanks 🙏! |
Report hasn't been filed before.
What version of
vscode-drizzle-orm
are you using?No response
Are you using Cursor or any other VSCode fork?
Is it related to
drizzle.run
?What version of
drizzle-lab
are you using?What version of
@drizzle-lab/api
are you using?Describe the Bug
Nextjs 15. Get the error that it can't find the index.mjs
The text was updated successfully, but these errors were encountered: