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

datePicker 组件类型相关问题 #7376

Closed
1 task
wowsummer opened this issue Feb 23, 2024 · 5 comments
Closed
1 task

datePicker 组件类型相关问题 #7376

wowsummer opened this issue Feb 23, 2024 · 5 comments
Labels

Comments

@wowsummer
Copy link

  • I have searched the issues of this repository and believe that this is not a duplicate.

Version

4.1.2

Environment

mac

Reproduction link

https://www.antdv.com/components/date-picker-cn

Steps to reproduce

两个问题:
一. RangePickerProps 无法导入

import type { RangePickerProps } from 'ant-design-vue'  // RangePickerProps 无法导入

二. a-date-picker 组件类型错误

<template>
   <a-date-picker v-bind="dateProps" /> // 组件会提示类型错误
</template>

<script lang="ts" setup>
import { ref } from 'vue'   
import type { DatePickerProps } from 'ant-design-vue'

const dateProps = ref<DatePickerProps>({ allowClear: true })
</script>

What is expected?

一. RangePickerProps 能正确导入
二. 不要提示类型错误

What is actually happening?

一. 无法导入RangePickerProps
二. 提示类型错误

@chouchouji
Copy link

image

好像并没有导出 RangePickerProps

@chouchouji
Copy link

第二个错误方便提供下报错的截图吗?

@wowsummer
Copy link
Author

感谢回复,截图如下
2

1

@chouchouji
Copy link

感谢回复,截图如下 2

1

类型没有匹配上,可以翻下node_modules深究具体原因
image

Copy link

This issue is stale because it has been open 60 days with no activity. Remove stale label or comment or this will be closed in 7 days

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

No branches or pull requests

2 participants