split string including whitespace as element of array javascript code example
Example: split by whitespace javascript
var text = "hoi how are you";
var arr = text.split(/\s+/);
var text = "hoi how are you";
var arr = text.split(/\s+/);