unplugin-vue-components
unplugin-vue-components copied to clipboard
ant-design-vue PageHeader无法自动导入
ide中输入APageheader可以自动补全,但实际运行时页面不显示该组件,控制台有警告
runtime-core.esm-bundler.js:38
[Vue warn]: Failed to resolve component: APageheader
If this is a native custom element, make sure to exclude it from component resolution via compilerOptions.isCustomElement.
use it like this
<template>
<a-page-header style="border: 1px solid rgb(235, 237, 240)" title="Title" sub-title="This is a subtitle"
@back="() => null" />
</template>
<script lang="ts">
import { defineComponent, onMounted, ref } from 'vue';
export default defineComponent({
setup() {
},
});
</script>
[Vue warn]: Failed to resolve component: a-pageheader
如果手动强行改为a-page-header,则ide提示Unknown html tag a-page-header
[ component name must be
a-page-header, which ide? try it with Volar plugin.
我用的是idea(webstorm同理)