Take your TypeScript skills to the next level with these intermediate challenges
Implement the built-in `ReturnType<T>` generic without using it. Learn conditional types with `infer` in this medium-level challenge on TypeScriptPro.
Implement a generic `TupleToUnion<T>` which covers the values of a tuple to its values union. Learn conditional types with `infer`, union type manipulation, tuple manipulation in this medium-level challenge on TypeScriptPro.
Chainable options are commonly used in Javascript. But when we switch to TypeScript, can you properly type it? Master advanced TypeScript type manipulation in this medium-level challenge on TypeScriptPro.
> TypeScript 4.0 is recommended in this challenge Learn array type operations in this medium-level challenge on TypeScriptPro.
> TypeScript 4.0 is recommended in this challenge Learn array type operations in this medium-level challenge on TypeScriptPro.
Type the function `PromiseAll` that accepts an array of PromiseLike objects, the returning value should be `Promise<T>` where `T` is the resolved result array. Learn array type operations, Promise type handling in this medium-level challenge on TypeScriptPro.
Sometimes, you may want to look up a type in a union by its attributes. Learn union type manipulation in this medium-level challenge on TypeScriptPro.
Implement `TrimLeft<T>` which takes an exact string type and returns a new string with the whitespace beginning removed. Master advanced TypeScript type manipulation in this medium-level challenge on TypeScriptPro.
Implement `Trim<T>` which takes an exact string type and returns a new string with the whitespace from both ends removed. Master advanced TypeScript type manipulation in this medium-level challenge on TypeScriptPro.
Implement `Capitalize<T>` which converts the first letter of a string to uppercase and leave the rest as-is. Master advanced TypeScript type manipulation in this medium-level challenge on TypeScriptPro.
Implement `Replace<S, From, To>` which replace the string `From` with `To` once in the given string `S` Master advanced TypeScript type manipulation in this medium-level challenge on TypeScriptPro.
Implement `ReplaceAll<S, From, To>` which replace the all the substring `From` with `To` in the given string `S` Master advanced TypeScript type manipulation in this medium-level challenge on TypeScriptPro.
For given function type `Fn`, and any type `A` (any in this context means we don't restrict the type, and I don't have in mind any type 😉) create a generic type which will take `Fn` as the first argument, `A` as the second, and will produce function type `G` which will be the same as `Fn` but with appended argument `A` as a last one. Master advanced TypeScript type manipulation in this medium-level challenge on TypeScriptPro.
Compute the length of a string literal, which behaves like `String#length`. Master advanced TypeScript type manipulation in this medium-level challenge on TypeScriptPro.
Implement a type that adds a new field to the interface. The type takes the three arguments. The output should be an object with the new field. Master advanced TypeScript type manipulation in this medium-level challenge on TypeScriptPro.
Implement the `Absolute` type. A type that take string, number or bigint. The output should be a positive number string Master advanced TypeScript type manipulation in this medium-level challenge on TypeScriptPro.
Implement the String to Union type. Type take string argument. The output should be a union of input letters Learn union type manipulation in this medium-level challenge on TypeScriptPro.
Merge two types into a new type. Keys of the second type overrides keys of the first type. Master advanced TypeScript type manipulation in this medium-level challenge on TypeScriptPro.
Replace the `camelCase` or `PascalCase` string with `kebab-case`. Master advanced TypeScript type manipulation in this medium-level challenge on TypeScriptPro.
Get an `Object` that is the difference between `O` & `O1` Master advanced TypeScript type manipulation in this medium-level challenge on TypeScriptPro.
Implement a type IsNever, which takes input type `T`. Learn union type manipulation in this medium-level challenge on TypeScriptPro.
Drop a specified char from a string. Master advanced TypeScript type manipulation in this medium-level challenge on TypeScriptPro.
Implement the type version of ```Array.reverse``` Learn tuple manipulation in this medium-level challenge on TypeScriptPro.
Looking for a tougher challenge? Try our hard challenges!
Be the first to access the course, unlock exclusive launch bonuses, and get special early-bird pricing before anyone else.
Only 27 Spots left
Get 1 month early access
Pre-Launch discount