News for hackers. Stuff that matters.
Re:Is React impacted by Meta layoff? by barbecue_sauce on Wednesday November 09, 2022 @12:47PM (#33535204)
I stopped using React around the time hooks were introduced, and never figured out what problem they were supposed to solve.
Re:Is React impacted by Meta layoff? by cercatrova on Wednesday November 09, 2022 @02:58PM (#33537019)
I have something that has a lifecycle and I don't want to initialize and destroy the state every time. I encapsulate that into a function, call it a hook, and go about my day knowing that I don't have to care about redoing the lifecycle every single time.

It's basically a class that has pre-written lifecycle functions.