Through
Render Props based component to receive data in the though-container. It pass props received from the through-agent to a function. The Function as Child Compnent (FaCC) approach is used.
Props from selected agent or whole area if bearingKey (or direct) prop is not specified.
Props
area
: String: The name of the area see GlossarybearingKey
: String|undefined: define which agent data is selected, or whole area data if undefineddirect
: String|bool|undefined: same asbearingKey
but alsoboolean
is allowed andtrue
is replaced withdefault
for direct mappingdefault
|defaultValue
: any: default value passed to the render function if no such agent exists or in initial renderingchildren
: function(props|area: Object): props from agent selected bybearingKey
ordirect
or whole area if not specified
Examples
Let Agent
is declared and two instanece of it are rendered some where in react tree like this:
Render data from each agent separtely
Render data using whole area
Last updated