I have a #TypeScript mapped type problem I don't know how to tackle:
I am looking for a way to turn this JS object: { a: true, b: false } into this
TS type: { a: string, b?: string }
Any pointers?
A static archive of Markus Tacker's tweets. Follow me on Mastodon: @[email protected].
I have a #TypeScript mapped type problem I don't know how to tackle:
I am looking for a way to turn this JS object: { a: true, b: false } into this
TS type: { a: string, b?: string }
Any pointers?