UNPKG

@cuppachino/type-space

Version:

A collection of type utilities for TypeScript.

9 lines (8 loc) 199 B
/** * Creates a type that is a union of readonly and mutable versions of `T`. */ export type IgnoreMutability<T> = { -readonly [K in keyof T]: T[K]; } | { readonly [K in keyof T]: T[K]; };