DEV Community

Discussion on: Clean Architecture: Applying with React

Collapse
 
jackmellis profile image
Jack

This is something I'm always keen on. I hate it when libraries for what could be framework-agnostic tools are tightly coupled to the framework.
"If you want to fetch the price of milk install this library and call useMilkPrice()"
What if I want to fetch the price of milk outside of a react context.
This has also been a big annoyance when moving between frameworks. A library that could easily be applied to a vue application has to be abandoned because it's tightly coupled to react.
I always prefer a core library and then a framework-specific wrapper or adapter library.
Rant over.