kevinmarrec / nuxt-pwa-module

⚠️ DEPRECATED ⚠️ Zero config PWA solution for Nuxt 3
MIT License
339 stars 32 forks source link

Error on the sharp module #86

Closed larsvdd closed 1 year ago

larsvdd commented 1 year ago

I'm trying to use the module, but I get an error as soon as I am trying to set an icon. If I set icon to false the other settings do work. I'd really like to have the icons working though.

I already tried reinstalling the sharp module, without success.

Any ideas?

/app/node_modules/sharp/lib/sharp.js:34
  throw new Error(help.join('\n'));
  ^

Error: 
Something went wrong installing the "sharp" module

Cannot find module '../build/Release/sharp-linuxmusl-x64.node'
Require stack:
- /app/node_modules/sharp/lib/sharp.js
- /app/node_modules/sharp/lib/constructor.js
- /app/node_modules/sharp/lib/index.js
- /app/node_modules/@kevinmarrec/nuxt-pwa/lib/generate.cjs

Possible solutions:
- Install with verbose logging and look for errors: "npm install --ignore-scripts=false --foreground-scripts --verbose sharp"
- Install for the current linuxmusl-x64 runtime: "npm install --platform=linuxmusl --arch=x64 sharp"
- Consult the installation documentation: https://sharp.pixelplumbing.com/install
    at Object.<anonymous> (/app/node_modules/sharp/lib/sharp.js:34:9)
    at Module._compile (node:internal/modules/cjs/loader:1159:14)
    at Module._extensions..js (node:internal/modules/cjs/loader:1213:10)
    at Module.load (node:internal/modules/cjs/loader:1037:32)
    at Module._load (node:internal/modules/cjs/loader:878:12)
    at Module.require (node:internal/modules/cjs/loader:1061:19)
    at require (node:internal/modules/cjs/helpers:103:18)
    at Object.<anonymous> (/app/node_modules/sharp/lib/constructor.js:8:1)
    at Module._compile (node:internal/modules/cjs/loader:1159:14)
    at Module._extensions..js (node:internal/modules/cjs/loader:1213:10)

Node.js v18.12.1

 ERROR  [unhandledRejection] 1

ℹ Vite client warmed up in 2459ms

 ERROR  Cannot restart nuxt:  1

 ERROR  (node:17) PromiseRejectionHandledWarning: Promise rejection was handled asynchronously (rejection id: 31)
kevinmarrec commented 1 year ago

Hey @larsvdd , sorry to hear that, could you give information about your Operating System ? As it looks like to be some compatibility issue.

kevinmarrec commented 1 year ago

Hey @larsvdd

Do you have any updates on this ?

ruslankonev commented 1 year ago

Same issue, macos, remove node_modules and install, fixed issue