Skip to content

Numeric separators support #28427

@DiegoFelipe

Description

@DiegoFelipe

This new feature is already in Chrome 75+

Large numeric literals are difficult for the human eye to parse quickly, especially when there are lots of repeating digits:

1000000000000
   1019436871.42

To improve readability, this JavaScript language feature enables underscores as separators in numeric literals. So, the above can now be rewritten to group the digits per thousand, for example:

1_000_000_000_000
    1_019_436_871.42

Now it’s easier to tell that the first number is a trillion, and the second number is in the order of 1 billion.

and here is it's repository:

https://github.com/tc39/proposal-numeric-separator

Metadata

Metadata

Assignees

No one assigned

    Labels

    questionIssues that look for answers.

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions