type-fest icon indicating copy to clipboard operation
type-fest copied to clipboard

How to have unknown keys return `never` with `Get` type?

Open tonyxiao opened this issue 1 year ago • 0 comments

import type {Get} from 'type-fest'

interface A { }

type abc = Get<A, ['/aa', 'ge2t']>

The result of abc is unknown, is there a way to make it return never instead?

Upvote & Fund

  • We're using Polar.sh so you can upvote and help fund this issue.
  • The funding will be given to active contributors.
  • Thank you in advance for helping prioritize & fund our backlog.
Fund with Polar

tonyxiao avatar Apr 06 '23 03:04 tonyxiao