MCPcopy
hub / github.com/vuejs/core / test

Function test

packages-private/dts-test/setupHelpers.test-d.ts:47–52  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

45
46describe('defineProps w/ generics', () => {
47 function test<T extends boolean>() {
48 const props = defineProps<{ foo: T; bar: string; x?: boolean }>()
49 expectType<T>(props.foo)
50 expectType<string>(props.bar)
51 expectType<boolean>(props.x)
52 }
53 test()
54})
55

Calls 1

definePropsFunction · 0.85

Tested by

no test coverage detected