I change number to string
ex)
721,011 => seven hundred twenty-one thousand eleven
21,011 => twenty-one thousand eleven
and i found split per three words
https://gist.github.com/hendriklammers/5231994
but it is splited at first word
721,011 => [721, 011] (It is perfect)
21,011 => [210, 11] (It is not perfect, wanna [21, 011])
2123011 => [212, 301, 1] (It is not perfect, wanna [2, 123, 011])
21230ef11 => [212, 301, 1] (It is not perfect, I'll accept only integer , wanna [2, 123, 011]), (using fucntion num.toString().replace(/\D/g, "") )
how to split string per length?
is it only reverse string and re reversing?