I'm trying to parse the contents of a token's GM Notes field to find a particular line of text. var gmNotes = npcToken.get("gmnotes"); var fullText = decodeURIComponent(gmNotes); var allLines = fullText.split("<p>"); allLines.some(function(line){ if (line.startsWith("TargetText")){ //dostuff } }); This works, but it isn't sitting right with me. Splitting on the paragraph tag feels wrong, but I'm not sure of a more efficient/cleaner way to do it. If anyone has any ideas, I'd appreciate it. :)