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

x轴scale里调用formatter,会把时间变成时间戳 #3466

Closed
1 task
Break-2020 opened this issue Jun 8, 2021 · 1 comment
Closed
1 task

x轴scale里调用formatter,会把时间变成时间戳 #3466

Break-2020 opened this issue Jun 8, 2021 · 1 comment

Comments

@Break-2020
Copy link

Break-2020 commented Jun 8, 2021

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

Reproduction link

Edit on CodeSandbox

Steps to reproduce

如链接所示,当x轴的值为yyyy-mm-dd,在x轴的scale中传入formatter,不做处理直接把val返回,x轴会被格式化成时间戳

有什么方法是可以不把它变成时间戳的吗,我在回调里需要处理别的类型的x轴,但是也有可能会有时间类型的传入,时间被转成时间戳不是预期想要的结果

Environment Info
g2 4.1.18
System 90.0.4430.93(正式版本) (64 位)
Browser Chrome
@hustcc
Copy link
Member

hustcc commented Jun 25, 2021

这个是一个存量的大问题,不是很好修复,在新版本 scale 修复了,但是迁移会导致 break change。

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

No branches or pull requests

2 participants