Skip to content

Add ability to customise number formatting when using format strings #724

@ammgws

Description

@ammgws

I was also wondering if decimal control could be integrated into the format string.

When thinking about things like the net or the speedtest block, it would be neat to be able to define the precision separately for the different displayed values. Ideally the syntax would allow to define all 3 arguments of the format_speed() function added in #704 / #707, like for example

Free: {free:3:G:B} for Free: 21.9GB

or

Uplink: {up:2:M:b}/s for Uplink: 50Mb/s

Originally posted by @GladOSkar in #714 (comment)

Metadata

Metadata

Assignees

No one assigned

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions