how to string.split by return event code example Example: split text by new line javascript myText.split(/\n/)