Explorar el Código

docs(create): Add troubleshooting section to new project readme(#2860)

callumhemming hace 1 año
padre
commit
e61c38dea5
Se han modificado 1 ficheros con 11 adiciones y 0 borrados
  1. 11 0
      packages/create/templates/readme.hbs

+ 11 - 0
packages/create/templates/readme.hbs

@@ -120,3 +120,14 @@ data that you cannot lose.
 ---
 
 You can also run any pending migrations manually, without starting the server via the "vendure migrate" command.
+
+---
+
+## Troubleshooting
+
+### Error: Could not load the "sharp" module using the \[OS\]-x\[Architecture\] runtime when running Vendure server.
+
+- Make sure your Node version is ^18.17.0 || ^20.3.0 || >=21.0.0 to support the Sharp library.
+- Make sure your package manager is up to date.
+- **Not recommended**: if none of the above helps to resolve the issue, install sharp specifying your machines OS and Architecture. For example: `pnpm install sharp --config.platform=linux --config.architecture=x64` or `npm install sharp --os linux --cpu x64`
+