美味的小圓
美味的小圓23h ago

deno install error for Nextjs Project

I'm using Deno 2.0.6 for now. But after I created Next.js app with create-next-app, I cd into the folder, deleted node_modules folder and run deno install --allow-scripts to re-install all modules with deno, but it give me the following error below:
error: script 'install' in 'sharp@0.33.5' failed with exit code 1
stderr:
error: [ERR_MODULE_NOT_FOUND] Cannot find module 'file:///<Project Path>/node_modules/.deno/sharp@0.33.5/node_modules/sharp/install/check' imported from 'file:///<Project Path>/node_modules/.deno/sharp@0.33.5/node_modules/sharp'

error: failed to run scripts for packages: sharp@0.33.5
error: script 'install' in 'sharp@0.33.5' failed with exit code 1
stderr:
error: [ERR_MODULE_NOT_FOUND] Cannot find module 'file:///<Project Path>/node_modules/.deno/sharp@0.33.5/node_modules/sharp/install/check' imported from 'file:///<Project Path>/node_modules/.deno/sharp@0.33.5/node_modules/sharp'

error: failed to run scripts for packages: sharp@0.33.5
Any idea about how to solve this? I think that this is problem of deno, I have already tried initializing nextjs project with other package manager (e.g. Bun, npm), there is no std error like this.
0 Replies
No replies yetBe the first to reply to this messageJoin