Posts under next
How to add type to useState while using TypeScript with React
Abhishek EH | Jul 30, 2022 | 2 Min Read
Guide on how to define type for useState hook while using react with TypeScript. Describes types for boolean, number, string, array and object. We will also see the type of setState function.