How to split string by digit?


#1

I use lodash, but I would like to split string by digit.

data = "123456";
I can split by 2 digits
=> ["12", "34", "56" ]

Please help me.


#2

Look great from lodash issue

data.match(/\d{2}/g)