ionic cordova resources 命令报错
Something went wrong installing the “sharp” module
[cordova-res]
[cordova-res] Cannot find module ‘…/build/Release/sharp.node’
[cordova-res]
[cordova-res] - Remove the “node_modules/sharp” directory, run “npm install” and look for errors
[cordova-res] - Consult the installation documentation at https://sharp.pixelplumbing.com/en/stable/install/
[cordova-res] - Search for this error at https://github.com/lovell/sharp/issues
[cordova-res]
[ERROR] An error occurred while running subprocess cordova-res.
cordova-res exited with exit code 1.
Re-running this command with the --verbose flag may provide more information.
git上面作者的回答
“Pre-compiled binaries for sharp are provided for use with Node versions 6, 8 and 10 on 64-bit Windows, OS X and Linux platforms.”
翻译:为64位Windows,OS X和Linux平台上的节点版本6,8和10提供了用于sharp的预编译二进制文件
意思就是sharp的node版本暂时只支持 6 8 10
切到支持的版本就行了 然后装了个10.8.0 完美!