SHARE
TWEET

Untitled

a guest Jul 12th, 2019 65 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. import { FormEventHandler } from 'react'
  2. type Prop = { a: number; onChange: () => number }
  3. type Other = { b: string; onChange: FormEventHandler }
  4. type Combined = Prop & Omit<Other, keyof Prop>
  5. function x(c: Combined) {
  6.   return c.onChange() // => number
  7. }
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
 
Top