TypeScript · Junior · Question 17 of 75

What does the utility type Partial<User> do?

Explanation

Partial<T> adds ? to every property - handy for update objects: update(id, patch: Partial<User>). Selecting a subset is Pick, read-only is Readonly, all required is Required.

Further reading

Problem with a question

TypeScript · Junior · question 17

Test yourself

Take the TypeScript · Junior quiz: questions and options are shuffled, and you get a review of your mistakes at the end.

Take this quiz