Skip to content

Commit

Permalink
Update failed test
Browse files Browse the repository at this point in the history
  • Loading branch information
johnsoncodehk committed Sep 6, 2024
1 parent 2d2ecdb commit f73483b
Showing 1 changed file with 10 additions and 7 deletions.
17 changes: 10 additions & 7 deletions test-workspace/tsc/passedFixtures/vue3/#4820/main.vue
Original file line number Diff line number Diff line change
@@ -1,19 +1,22 @@
<script lang="ts">
type Foo = {
a: string;
b: number;
a: string;
b: number;
};
declare function func<TFoo extends Foo>(foo: TFoo, fooKey: keyof TFoo): any;
</script>

<script setup lang="ts" generic="TFoo extends Foo, TFooKey extends keyof TFoo">
const { foo, fooKey } = defineProps<{
foo: TFoo,
fooKey: TFooKey
const { foo, fooKey, ...props } = defineProps<{
foo: TFoo;
fooKey: TFooKey;
bar: TFoo;
barKey: TFooKey;
}>();
</script>

<template>
{{ func(foo, fooKey) }}
</template>
{{ func(foo, fooKey) }}
{{ func(props.bar, props.barKey) }}
</template>

0 comments on commit f73483b

Please sign in to comment.