project_nextjs13_flexibble
project_nextjs13_flexibble copied to clipboard
Deployment building error
I am getting the error while deploying it. Error shows like this:
[17:52:30.711] Running build in Washington, D.C., USA (East) – iad1
[17:52:30.857] Cloning github.com/1999-sahil/geekgazette-nextjs-app (Branch: main, Commit: 47cdc17)
[17:52:30.867] Skipping build cache, deployment was triggered without cache.
[17:52:31.146] Cloning completed: 289.245ms
[17:52:31.487] Running "vercel build"
[17:52:32.001] Vercel CLI 32.6.1
[17:52:32.406] Installing dependencies...
[17:52:47.304]
[17:52:47.308] added 168 packages in 14s
[17:52:47.308]
[17:52:47.308] 29 packages are looking for funding
[17:52:47.308] run npm fund
for details
[17:52:47.348] Detected Next.js version: 13.4.19
[17:52:47.358] Detected package-lock.json
generated by npm 7+
[17:52:47.360] Running "npm run build"
[17:52:49.519]
[17:52:49.519] > [email protected] build
[17:52:49.519] > next build
[17:52:49.519]
[17:52:50.025] - warn You have enabled experimental feature (serverComponentsExternalPackages) in next.config.js.
[17:52:50.026] - warn Experimental features are not covered by semver, and may cause unexpected or broken application behavior. Use at your own risk.
[17:52:50.026]
[17:52:50.053] Attention: Next.js now collects completely anonymous telemetry regarding usage.
[17:52:50.053] This information is used to shape Next.js' roadmap and prioritize features.
[17:52:50.053] You can learn more, including how to opt-out if you'd not like to participate in this anonymous program, by visiting the following URL:
[17:52:50.054] https://nextjs.org/telemetry
[17:52:50.054]
[17:52:50.150] - info Creating an optimized production build...
[17:53:15.311] - warn Compiled with warnings
[17:53:15.311]
[17:53:15.312] ./node_modules/node-fetch/lib/index.js
[17:53:15.312] Module not found: Can't resolve 'encoding' in '/vercel/path0/node_modules/node-fetch/lib'
[17:53:15.312]
[17:53:15.312] Import trace for requested module:
[17:53:15.312] ./node_modules/node-fetch/lib/index.js
[17:53:15.312] ./node_modules/cross-fetch/dist/node-ponyfill.js
[17:53:15.312] ./node_modules/graphql-request/build/esm/index.js
[17:53:15.312] ./lib/actions.ts
[17:53:15.312] ./components/ProjectForm.tsx
[17:53:15.312]
[17:53:15.314] - info Linting and checking validity of types...
[17:53:21.348] Failed to compile.
[17:53:21.348]
[17:53:21.348] ./app/project/[id]/page.tsx:30:29
[17:53:21.348] Type error: Type 'string | undefined' is not assignable to type 'string | StaticImport'.
[17:53:21.348]
[17:53:21.348] [0m [90m 28 | [39m [33m<[39m[33mLink[39m href[33m=[39m{renderLink()}[33m>[39m[0m
[17:53:21.349] [0m [90m 29 | [39m [33m<[39m[33mImage[39m[0m
[17:53:21.349] [0m[31m[1m>[22m[39m[90m 30 | [39m src[33m=[39m{projectDetails[33m?[39m[33m.[39mcreatedBy[33m?[39m[33m.[39mavatarUrl}[0m
[17:53:21.349] [0m [90m | [39m [31m[1m^[22m[39m[0m
[17:53:21.349] [0m [90m 31 | [39m width[33m=[39m{[35m50[39m}[0m
[17:53:21.349] [0m [90m 32 | [39m height[33m=[39m{[35m50[39m}[0m
[17:53:21.349] [0m [90m 33 | [39m alt[33m=[39m[32m"profile"[39m[0m
[17:53:21.463] Error: Command "npm run build" exited with 1
[17:53:21.796]
Please help me to resolve this issue.