Answers for "typescript lambda type parameter"

0

typescript lambda type parameter

// For .ts (not .tsx)
const func = <T>() => { 
}

// For react Typescript (.tsx)
const func = <T,>() => {
}

// For older versions of react typescript
const func = <T extends unknown>() => {
  
}
Posted by: Guest on April-19-2021

Code answers related to "typescript lambda type parameter"

Code answers related to "TypeScript"

Browse Popular Code Answers by Language