react-polyglot icon indicating copy to clipboard operation
react-polyglot copied to clipboard

Improve typing file to be more accurate when using HOC

Open soda0289 opened this issue 5 years ago • 0 comments

Current the types remove some of the props typings when using the HOC. For example I have components that return functions instead of elements. Since children is not part of the Prop type it did not get copied over. Same thing will happen with static types as well.

I copied the types that react-redux is using which seem to work better. We could also add some tests but would need typescript installed in the repo.

soda0289 avatar Aug 12 '19 21:08 soda0289