Tech Lead/Team Lead. Senior WebDev.
Intermediate Grade on Computer Systems-
High Grade on Web Application Development-
MBA (+Marketing+HHRR).
Studied a bit of law, economics and design
Location
Spain
Education
Higher Level Education Certificate on Web Application Development
You can decouple logic from react components without adding layers of abstraction other than the ones you'll get by default -usually- i.e. with HOCs (High Order Components) can be used for more things than just to increment New functionalities for other components. With HOCs you can actually separate responsibilities too.
You can create a HOC that accepts a React component as an argument, implements the data logic, and passes data, loading, and error as props into the wrapped React component.
This way your data and/or logic is decoupled from the UI.
For further actions, you may consider blocking this person and/or reporting abuse
We're a place where coders share, stay up-to-date and grow their careers.
You can decouple logic from react components without adding layers of abstraction other than the ones you'll get by default -usually- i.e. with HOCs (High Order Components) can be used for more things than just to increment New functionalities for other components. With HOCs you can actually separate responsibilities too.
You can create a HOC that accepts a React component as an argument, implements the data logic, and passes data, loading, and error as props into the wrapped React component.
This way your data and/or logic is decoupled from the UI.