Next.js Discord

Discord Forum

NextJS TurboRepo Failing to build on production VERCEL

Unanswered
Black Guillemot posted this in #help-forum
Open in Discord
Black GuillemotOP
All environment variables set properly, settings are completely identical to it's STAGING twin.

5 Replies

Black GuillemotOP
here is the full error in text

> web@0.1.0 build /vercel/path0/apps/web
> next build
- info Linting and checking validity of types...
- error ESLint: Failed to load plugin 'unicorn' declared in '.eslintrc.json': Cannot find module 'eslint-plugin-unicorn' Require stack: - /vercel/path0/apps/web/__placeholder__.js Referenced from: /vercel/path0/apps/web/.eslintrc.json
Failed to compile.
./components/activities/camera.tsx:1:42
Type error: Could not find a declaration file for module 'react'. '/vercel/path0/node_modules/.pnpm/react@18.2.0/node_modules/react/index.js' implicitly has an 'any' type.
  If the 'react' package actually exposes this module, consider sending a pull request to amend 'https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/react'
> 1 | import React, { useEffect, useRef } from "react";
    |                                          ^
  2 | 
  3 | export default function Camera() {
  4 |   const videoReference = useRef<HTMLVideoElement>(null);
 ELIFECYCLE  Command failed with exit code 1.
Error: Command "pnpm -w package.build && pnpm build" exited with 1
and react does get installed properly
Black GuillemotOP
ok i tried force rebuilding and for some reason it just can't find my node modules
oh for crying out loud