Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: 将导出的组件加上前缀,无需手动按需导入时重命名 #8106

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

hsbtr
Copy link

@hsbtr hsbtr commented Mar 31, 2025

现在的组件使用的时候有两种方式,自动导入与手动导入; 但手动导入需要在导入的时候重新命名,如:

<script setup>
import { Form as AForm } from ''ant-design-vue'
</script>
<template>
  <a-form></a-form>
</template>

不如此使用的话,小写使用就会与关键字冲突,所以我在库的内部改变了每个组件导出的名字,自动导入或全局注册会造成组件无法读取到声明,开发过程中这样很难通过组件直接转入到组件声明文件

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant