Similar to the following question: With getComponent how to pass props?
I am trying to pass props to getComponents():
getComponents: (nextState, cb) => {
cb(null, props => {
return {
left: <LeftContainer {...props} items={items} />
center: <CenterContainer {...props} items={centerItems} />
};
});
}
For some reason, in my parent route I don't get this.props.left and this.props.center, instead I see this.props.children. And if I try to render it, getComponents() is called but then it expects an array of components and not an object. Am I doing something wrong here?