Saturday, 21 January 2023

NextJS console logs TypeError on console everytime I make a request on localhost: Cannot read properties of undefined (reading '_owner')

I just have created a simple NextJS project following couple of tutorials, it's TypeScript included, but after I npm run dev I see below log on console

TypeError: Cannot read properties of undefined (reading '_owner')
    at t (backend.bundle.js:1:119865)
    at t (backend.bundle.js:1:122074)
    at t (backend.bundle.js:1:122074)
    at t (backend.bundle.js:1:122074)
    at t (backend.bundle.js:1:122106)
    at t (backend.bundle.js:1:122074)
    at t (backend.bundle.js:1:122074)
    at t (backend.bundle.js:1:122074)
    at t (backend.bundle.js:1:122074)
    at t (backend.bundle.js:1:122074)
    at t (backend.bundle.js:1:122074)
    at t (backend.bundle.js:1:122074)
    at t (backend.bundle.js:1:122074)
    at t (backend.bundle.js:1:122074)
    at t (backend.bundle.js:1:122074)
    at t (backend.bundle.js:1:122074)
    at t (backend.bundle.js:1:122106)
    at t (backend.bundle.js:1:122074)
    at t (backend.bundle.js:1:122074)
    at t (backend.bundle.js:1:122074)
    at E (backend.bundle.js:1:122126)
    at n (backend.bundle.js:1:123584)
    at c (backend.bundle.js:1:123643)
    at backend.bundle.js:1:124007
    at 496 (backend.bundle.js:1:125067)
    at i (backend.bundle.js:1:110)
    at backend.bundle.js:1:902
    at backend.bundle.js:1:913

The project works properly, it doesn't block anything, but why am I seeing this log everytime?

I also tried to start new projects using create-next-app and just ran the project, but still even everything is created by default (I didn't even touch any file) I still got the above error message.

Everytime I make request to a URL on localhost, it logs the above error message. I have no idea what's this, I think it comes from NextJS inside, it's not even relevant to my codes (I don't even have a variable or something called "owner" or even "own")

Why I see this error message on the console? How can I get rid off it?,

Edit: After I've added couple of elements, It has started to throw this too

TypeError: Cannot read properties of undefined (reading '0')
    at t (backend.bundle.js:1:119861)
    at t (backend.bundle.js:1:122074)
    at t (backend.bundle.js:1:122074)
    at t (backend.bundle.js:1:122074)
    at t (backend.bundle.js:1:122074)
    at t (backend.bundle.js:1:122074)
    at t (backend.bundle.js:1:122074)
    at t (backend.bundle.js:1:122074)
    at t (backend.bundle.js:1:122074)
    at t (backend.bundle.js:1:122074)
    at t (backend.bundle.js:1:122074)
    at t (backend.bundle.js:1:122074)
    at t (backend.bundle.js:1:122074)
    at t (backend.bundle.js:1:122074)
    at t (backend.bundle.js:1:122074)
    at t (backend.bundle.js:1:122074)
    at t (backend.bundle.js:1:122074)
    at t (backend.bundle.js:1:122074)
    at t (backend.bundle.js:1:122106)
    at t (backend.bundle.js:1:122074)
    at t (backend.bundle.js:1:122074)
    at E (backend.bundle.js:1:122126)
    at n (backend.bundle.js:1:123584)
    at c (backend.bundle.js:1:123643)
    at backend.bundle.js:1:124007
    at 496 (backend.bundle.js:1:125067)
    at i (backend.bundle.js:1:110)
    at backend.bundle.js:1:902
    at backend.bundle.js:1:913

Because of this console messages, after 5-10 renders, on console I see 500+ messages and this is frustrating. How can I get rid of this issue?



from NextJS console logs TypeError on console everytime I make a request on localhost: Cannot read properties of undefined (reading '_owner')

No comments:

Post a Comment