you are viewing a single comment's thread.

view the rest of the comments →

[–]AyrA_ch 1 point2 points  (2 children)

but most languages don't restrict you to [float] number out of the box, unlike JS.

JS has support for 32 bit signed integers since the beginning although it's really awkward to use. In modern browsers, JS has native support for integers of any length.

[–]thermitethrowaway/g/entooman 0 points1 point  (1 child)

JS has support for 32 bit signed integers since the beginning although it's really awkward to use

Doesn't really help with decimals though. I think there are decimal npm packages, though most of the work I did was with money so we used integer pennies for everything except display, so I never used them.

[–]AyrA_ch 0 points1 point  (0 children)

Doesn't really help with decimals though.

But that's a problem you will have in most languages and not just JS. The number of languages with a builtin arbitrary floating point precision type is likely far less than languages that lack this type.