When writing TypeScript there's a pretty easy, simple solution to ... type Immutable<T> = { readonly [K in keyof T]: Immutable<T[K]>; }.
確定! 回上一頁