by Zheeeng @zheeeng
Implement the advanced util type GetOptional<T>
, which remains all the optional fields
For example
type I = GetOptional<{ foo: number, bar?: string }> // expected to be { bar?: string }
by Zheeeng @zheeeng
Implement the advanced util type GetOptional<T>
, which remains all the optional fields
For example
type I = GetOptional<{ foo: number, bar?: string }> // expected to be { bar?: string }