Skip to content

ASwitch onchange event handler params type define incorrect #4615

@daiwanxing

Description

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

Version

2.2.6

Environment

windows10, chrome 92, vue 3.2

Reproduction link

https://github.com/daiwanxing/issue-repo

Steps to reproduce

  1. 在JSX中使用ASwitch组件
  2. 给ASwitch组件onChange事件注册一个回调函数, 回调函数中定义了一个形参,该形参被ts推断成了any类型,而不是CheckedType类型

What is expected?

应该被正确推断为CheckedType类型

What is actually happening?

实际该形参被推断成了any类型

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions