TypeScript
11 tips tagged with #typescript.
- Separate large numbers in TypeScript with underscore
- Assert that all possible cases in a switch statement are handled
- Define an array with a min length in TypeScript
- TypeScript supports arrays with the rest syntax at the beginning
- Check if a string is a valid enum value in TypeScript
- Create a string type in a specific format in TypeScript
- Extract types in TypeScript
- Exclude certain types in TypeScript
- React function component without children in TypeScript
- Custom hooks should return named tuples and not use "as const"
- Replace any with generics, not with unknown (in many cases)