App reviews, troubleshooting, and recommendations
An error occurred in compiling and packaging, and the vite packaging path is wrong.
D:\code\bundle-app>yarn build
yarn run v1.22.19
$ shopify app build
product-discount │ Building GraphQL types...
frontend │
frontend │ > discount-frontend@1.0.0 build
frontend │ > vite build
frontend │
frontend │
frontend │ > discount-frontend@1.0.0 build
frontend │ > vite build
frontend │
frontend │
frontend │ > discount-frontend@1.0.0 build
frontend │ > vite build
frontend │
frontend │ node:internal/modules/cjs/loader:1078
frontend │ throw err;
frontend │ ^
frontend │
frontend │ Error: Cannot find module 'D:\code\bundle-app\node_modules\node_modules\vite\bin\vite.js'
frontend │ at Module._resolveFilename (node:internal/modules/cjs/loader:1075:15)
frontend │ at Module._load (node:internal/modules/cjs/loader:920:27)
frontend │ at Function.executeUserEntryPoint [as runMain] (node:internal/modules/run_main:81:12)
frontend │ at node:internal/main/run_main_module:23:47 {
frontend │ code: 'MODULE_NOT_FOUND',
frontend │ requireStack: []
frontend │ }
frontend │
frontend │ Node.js v18.16.0
── external error ────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────
Error coming from `npm run build`
Command failed with exit code 1: npm run build
node:internal/modules/cjs/loader:1078
throw err;
^
Error: Cannot find module 'D:\code\bundle-app\node_modules\node_modules\vite\bin\vite.js'
at Module._resolveFilename (node:internal/modules/cjs/loader:1075:15)
at Module._load (node:internal/modules/cjs/loader:920:27)
at Function.executeUserEntryPoint [as runMain] (node:internal/modules/run_main:81:12)
at node:internal/main/run_main_module:23:47 {
code: 'MODULE_NOT_FOUND',
requireStack: []
}
Node.js v18.16.0
> discount-frontend@1.0.0 build
> vite build
──────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────
error Command failed with exit code 1.
info Visit https://yarnpkg.com/en/docs/cli/run for documentation about this command.
Discover how to increase customer engagement on your store with articles from Shopify A...
By Jacqui Apr 23, 2025Hey Community 👋 Did you know that March 15th is National Everything You Think Is W...
By JasonH Apr 1, 2025Discover how to increase the efficiency of commerce operations with Shopify Academy's l...
By Jacqui Mar 26, 2025