[@vue/compiler-sfc] Failed to resolve index type into finite keys
Vue version
lastest
Link to minimal reproduction
Steps to reproduce
<script setup lang="ts">
import type { InputNumberProps } from 'naive-ui';
const { componentProps } = defineProps<InputNumberProps>();
const slots = useSlots();
</script>
[vite] Internal server error: [@vue/compiler-sfc] Failed to resolve index type into finite keys
E:/projects/stp-web/node_modules/naive-ui/es/_utils/naive/extract-public-props.d.ts
3 | type themePropKeys = keyof typeof useTheme.props;
4 | type RemoveReadonly<T> = {
5 | -readonly [key in keyof T]: T[key];
| ^^^^^^^
6 | };
7 | export type ExtractPublicPropTypes<T> = Omit<Partial<RemoveReadonly<ExtractPropTypes<T>>>, Exclude<themePropKeys, 'themeOverrides'> | Extract<keyof T, `internal${string}`>>;
What is expected?
Fix this error, otherwise Support imported types in SFC macros seems pointless
What is actually happening?
[@vue/compiler-sfc] Failed to resolve index type into finite keys #9111
System Info
window
Any additional comments?
No response
<script setup lang="ts">
import type { InputNumberProps } from 'naive-ui';
const { componentProps } = defineProps<InputNumberProps>();
const slots = useSlots();
</script>
@edison1105 Where should I set /@vue-ignore/
Duplicate of #8266
Does this mean that v3.3 still cannot use external props?
It's not a yes or no question. Please read the two comments I provided. I believe they have explained it in enough detail.
Where should I set /@vue-ignore/
<script setup lang="ts">
import type { InputNumberProps } from 'naive-ui';
Where should I set /@vue-ignore/
const { componentProps } = defineProps<InputNumberProps>();
const slots = useSlots();
</script>
@sxzz Thank you for your help. I have already read it, but I set /@vue-ignore/, it will still report an error