import { RecursivePartial , OptionalKeys , RequiredKeys } from './TypeUtil' ; interface UserSettings { one : { four : number ; three : number ; } ; } type SomePartial = Partial < UserSettings > ; const invalidPartial = { three : 3 } ; type AllPartial = RecursivePartial < UserSettings > ; const allPartial = { three : 3 } ; interface MessageSettings { content : string ; expired ? : boolean ; recipient : string ; sent ? : boolean ; } const optionalKeys = [ 'expired' ] ; const requiredKeys = [ 'content' ] ; const invalidKeys = [ 'content' ] ; allPartial ; optionalKeys ; requiredKeys ; invalidKeys ;