DekGenius.com
Home
(current)
Dictionary
BOOKS
LYRICS
CHORD
SCRIPT & CODE EXAMPLE
Karaoke language
Search
Go
SCRIPT & CODE EXAMPLE
CODE EXAMPLE FOR JAVASCRIPT
javascript format number with commas
let
n
=
234234234
;
let
str
=
n
.
toLocaleString
(
"en-US"
)
;
console
.
log
(
str
)
;
// "234,234,234"
Source by sebhastian.com #
PREVIOUS
NEXT
Tagged:
#javascript
#format
#number
#commas
ADD COMMENT
Topic
COMMENT
Name
5+6 =
Submit