withDefaults({ host: 'custom.com' }, { host: 'localhost', port: 3000 })
// β { host: 'custom.com', port: 3000 }withDefaults merges user options over defaults, filling in only properties that are not already set.
Challenge: Implement withDefaults<T extends object>(input: Partial<T>, defaults: Required<T>): Required<T> filling missing fields from defaults.
withDefaults({ a: 1 }, { a: 10, b: 20 }) // β { a: 1, b: 20 }