toArray :: String

toArray() -> [character...]

 

Splits the string character-by-character and returns an array with the result.

 

Examples

 

'a'.toArray();

// -> ['a']

 

'hello world!'.toArray();

// -> ['h', 'e', 'l', 'l', 'o', ' ', 'w', 'o', 'r', 'l', 'd', '!']


Prototype API 1.5.0 - prototypejs.org