Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR JAVASCRIPT

js string to array

// string
let string = '12345';

// splits characters string into items in our array
let array = string.split('');

console.log(array); // [ "1", "2", "3", "4", "5"]
Source by stackoverflow.com #
 
PREVIOUS NEXT
Tagged: #js #string #array
ADD COMMENT
Topic
Name
3+2 =