How to make a property of an object is read-only using typescript
Readonly<Type>
It will set all the properties of Type to read-only, which means the properties of the Type cannot be reassigned.
Let's see with an example so that we can understand easily
interface Person {
name: string,
age: number
}
let pe...
jkpulipati.hashnode.dev1 min read