1

I have few strings 'ABCDEF', 'GHIJKL' ... I need to split them by 3 and 3 symbols to array.

var str = 'ABCDEF';
str.split(3)
// need return array('ABC','DEF');

Is ther a way to do it beautifully?

Sergey Kudryashov
  • 713
  • 2
  • 9
  • 30

0 Answers0