Effect CommunityEC
Effect Community8mo ago
17 replies
Aleks M

Using a Hook to Access Rx Runtime in Effect: Potential Pitfalls?

If I follow effect website patterns, I can clearly see Rx runtimes being created at the top level, as well as Rx values themselves, which is kinda undermines testing, since runtime is sealed and I can't substitute layers with test implementations.
For my project I put it in a hook, accessing Rx runtime with use(RuntimeContext)
Any pitfalls one can notice in such an approach?
Was this page helpful?