Skip to main content
Journey Uncommon Logo
JourneyUncommon
mediumTypeScriptgeneric defaultsSingle-choice MCQ

With a defaulted type parameter, what is the type of `b` when an argument is provided?

function make<T = boolean>(x?: T): T { return x as T; } const b = make("hi");