Skip to content

How can I change the time format in the x Axis dynamic label?  #355

@Monox18

Description

@Monox18

Hello. Little Javascript knowledge here. How can I change the date format in the x Axis dynamic label? (red arrow in the screenshot) Basically I want to change it to day/month/year instead of month/day/year

Screenshot 2020-11-05 16 08 19

I was able to display milliseconds in the "t:" with
tzDate: ts => uPlot.tzDate(new Date(ts * 1e3), 'Etc/UTC'),
and
series: [ { label: "t", value: (u, ts) => fmtDate(tzDate(ts)), }

but I can't find a way to use fmtDate to change the x label as I want

Metadata

Metadata

Assignees

No one assigned

    Labels

    demosquestionFurther information is requested

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions