And we'd have to pass in something into stuff, which is of type <TOriginalProps & InjectedProps> Is that right?
So what's the point of having injected props calculated within the HOC definition? Am I missing something? If I want to render the Demo HOC, don't I have to give it all the props it needs? I think I'm missing the point...
Hey there Dan,
MadPropsfor this article.Going forward with this example, how would you use ReactDOM.render with this component?
Say we continue with this:
Then our calling code would do
And we'd have to pass in something into
stuff, which is of type<TOriginalProps & InjectedProps>Is that right?So what's the point of having injected props calculated within the HOC definition? Am I missing something? If I want to render the
DemoHOC, don't I have to give it all the props it needs? I think I'm missing the point...Hi, thanks for the
MadProps:)<Demo>has props of typeTOriginalProps & ExternalProps(noInjectedProps).<DemoComponent>has props of typeTOriginalProps & InjectedProps.Look at the diagram at the start of the article, it should make the prop types flow clearer :)