How to do generic type transferring with jsx in TypeScript

added by JavaScript Kicks
11/19/2018 8:34:17 AM

403 Views

So I just encountered a problem where I want to make a better type checking in a props of a React component. It's about one prop takes an array of certain type, and in another prop callback, where this type needs to be the parameter. Let's see how to do that in TypeScript.


0 comments