- Container component includes shouldComponentUpdate optimisation and passes its props into wrapped component.
- Subscription function should accept hz function as the first argument which should be used to construct a query using Collection API and return it.
- Client demand is specified by colocating Horizon queries on React components using connect function that expects React component and config object as arguments and returns a container component which has an access to an instance of Horizon .
- It will be passed into component directly as a prop it’s possible to call any type of mutation operations from within component.
- Taking inspiration from Relay library React Horizon provides a special component HorizonRoute .
Read the full article, click here.
@roman01la: “Hey @horizonjs, I’ve built a binding library of Horizon client for @reactjs, check it out”
In this article I introduce a work in progress idiomatic solution for React applications built on top of Horizon’s client library which can…
Introducing React Horizon — Medium