Completed Challenges
Currying 1
TypeScript 4.0 is recommended in this challenge
[Currying](https://en.wikipedia.org/wiki/Curryi
Chainable Options
Chainable options are commonly used in Javascript. But when we switch to TypeScript, can you prope
Deep Readonly
Implement a generic DeepReadonly<T>
which make every parameter of an object - and its sub-object
Get Return Type
Implement the built-in ReturnType<T>
generic without using it.
For example
const fn = (v
Omit
Implement the built-in Omit<T, K>
generic without using it.
Constructs a type by picking all pr
Readonly 2
Implement a generic MyReadonly2<T, K>
which takes two type argument T
and K
.
K
specify th
Get Optional
Implement the advanced util type GetOptional<T>
, which remains all the optional fields
For exam
Generic Function Arguments
Give generic function types to your functions
Generic Type Arguments
Generic types are like function arguments.
Tuple to Union
Implement a generic TupleToUnion<T>
which covers the values of a tuple to its values union.
For
Get Required
Implement the advanced util type GetRequired<T>
, which remains all the required fields
For exam
Required Keys
Implement the advanced util type RequiredKeys<T>
, which picks all the required keys into a union
Simple Vue
Implement a simpiled version of a Vue-like typing support.
By providing a function name `SimpleVu
Union to Intersection
Implement the advanced util type UnionToIntersection<U>
For example
type I = UnionToInte
Optional Keys
Implement the advanced util type OptionalKeys<T>
, which picks all the optional keys into a union
Capitalize Words
Implement CapitalizeWords<T>
which converts the first letter of each word of a string to upp
Get Readonly Keys
Implement a generic GetReadonlyKeys<T>
that returns a union of the readonly keys of an Object.