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

perf(util): remove handleInputNumberValue #3806

Merged
merged 2 commits into from
May 1, 2024

Conversation

electroluxcode
Copy link

@electroluxcode electroluxcode commented Apr 30, 2024

fix:#3805

General

✏️ Mark the necessary items without changing the structure of the PR template.

  • Pull request template structure not broken

Pull request template structure not broken

历史遗留问题

当初这个函数的提出是为了解决这个默认值的bug( #3274 ),但是默认值的问题没有彻底解决

直到 #3287 之后才把这个问题大体解决了(定位问题是在isEmpty的使用上面,而跟这个函数没有什么关系)。这时handleInputNumberValue这个函数不仅没发挥到应有的作用,并且导致了input系列组件输入输出类型不一致的问题 。例如输入number,string,其他的数据都会变成string

最近 #3802 pr提过之后,目前的行为是 number变成number,然后其他的都变成string,但是仍然导致了 null 和 undefined等其他类型 会被设置成 string类型。

@wangjue666
Copy link
Collaborator

看下ci 有类型问题

@electroluxcode
Copy link
Author

看下ci 有类型问题

okok,已解决

@wangjue666 wangjue666 merged commit ba5b8f8 into vbenjs:main May 1, 2024
2 checks passed
@vbenjs vbenjs locked and limited conversation to collaborators Aug 3, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants