Skip to content

v4 version ticks collback return timestamp, v3 returned time in string #11062

Answered by stockiNail
Aaqu asked this question in Q&A
Discussion options

You must be logged in to vote

@Aaqu the solution is working even if you are forced to "re-apply" the configuration you have on the time config node.

To avoid that, you could try:

  callback(value) {
    return this.getLabelForValue(value).split(' '); // <--- this is the scale instance.
  }

In this way you could also change your time adapter (maybe using moment or date-fns) and it works without changing the code.

Replies: 1 comment 5 replies

Comment options

You must be logged in to vote
5 replies
@Aaqu
Comment options

@stockiNail
Comment options

@Aaqu
Comment options

@stockiNail
Comment options

@Aaqu
Comment options

Answer selected by Aaqu
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants