I am looking to a regex expression to remove the carriage return and any following whitespace on the next line of a string.
I should be able to work it out but have a real blind spot when it comes to regex.
I know about appendChild and insertBefore and so on. It's just there are some cases where direct string manipulation may make things a lot easier but flatteningit out would make it more so.
<span>tabs or spaces</span>
<div><span>tabs or spaces</span></div>