News for hackers. Stuff that matters.
Re:Solid.js feels like what I always wanted React to be by tinganho on Tuesday March 01, 2022 @07:35AM (#30513339)
I think in the class world this is normally done by writing a service and injecting it on the constructor of the parent class. Since, React doesn't have DI built-in, it becomes problematic with the injection. hooks are essentially classes imo.
Re:Solid.js feels like what I always wanted React to be by arcosdev on Tuesday March 01, 2022 @08:04AM (#30513591)
How does it become problematic? You just pass in dependencies as arguments to functions or components.