Ranter
Join devRant
Do all the things like
++ or -- rants, post your own rants, comment on others' rants and build your customized dev avatar
Sign Up
Pipeless API
From the creators of devRant, Pipeless lets you power real-time personalized recommendations and activity feeds using a simple API
Learn More
Comments
-
I usually get that error when I'm using this.state = ....
Outside the constructor
Another possibility having two set state calls right after each other, but idoubt that's your case
Or if setState is called in render function -
@gitpush I have a hunch of where the problem is but I can’t debug it now, I need to sleep on the problem and come back reinvigorated tomorrow...
-
Can almost always be solved by breaking up the component into smaller, data driven parts.
-
@linuswillner best of luck and you made the right decision here, rest and tomorrow you'll be in a better situation to solve it
-
@NoMaDhOoK Didn’t read your comments until now, but what do you know, it was exactly as you described - I was calling setState within render inadvertently. Coding at 2 AM is really fickle
-
@linuswillner yup, take my advice whenever you can sleep early and begin your day around 5, I'm most productive between 5:30am and 8am, then I become lazy af lol
Related Rants
You know that feeling when you're coding late at night and you get an error that you just can't parse with your tired brain, and go FUCK IT ALL, FUCK IT ALL
I'm having that feeling right about now...
rant
late night coding
error
fuck this shit
react
js