Sep 19, 2022
At the point that you do this, you start to realize why hooks are a bad idea--they discourage good patterns that are tried-and-true. At the point that you're injecting the _result_ of calling a hook function, you could inject something that's going to be more robust. The entire point of hooks is to encourage developers to just reach out and grab what they want from within components vs. providing it as an explicit dependency.