0

I successfully build next.js app, opened the app at public IP, and after a couple of seconds the app crashed with this stack trace. At the developing / localhost environment, everything works fine.

Could you please someone help me to understand how can I find and reason for the crash? I am new to next.js. Thanks a lot.

Here is a screenshot from my Console with stac trace

"TypeError: Cannot read properties of null (reading 'content')
    at main-debe05f3274b8de7.js:1:11764
    at main-debe05f3274b8de7.js:1:12241
    at Array.forEach (<anonymous>)
    at Object.updateHead (main-debe05f3274b8de7.js:1:11612)
    at Object.t [as _pendingUpdate] (main-debe05f3274b8de7.js:1:87363)
    at main-debe05f3274b8de7.js:1:87802
    at Ui (framework-5f4595e5518b5600.js:1:104662)
    at t.unstable_runWithPriority (framework-5f4595e5518b5600.js:1:129336)
    at Ql (framework-5f4595e5518b5600.js:1:44981)
    at Fi (framework-5f4595e5518b5600.js:1:104123)"

I just tried to run the app after successfull build. enter image description here

Guminator
  • 1
  • 1
  • 2
  • This seems like a bug in your code. In your main.js, there is a null variable and you're trying to read `content` from it – Brian Jan 21 '23 at 17:24
  • Hi @Brian, thank you for your reply. The problem is that my project of next.js does not contain any file with the name main.js. – Guminator Jan 23 '23 at 15:26

0 Answers0