Skip to main content
5 events
when toggle format what by license comment
Jan 25, 2022 at 16:26 comment added Blindman67 @konijn Thanks. Note that querySelectorAll returns an array like object and thus would require at least a spread operator. to work. eg [...document.querySelectorAll("span, p, strong")].filter(
Jan 25, 2022 at 13:56 comment added konijn +1'd the answer, though for the brute force I would have split the forEach into a filter and a forEach, it would be semantically correct, and slower.
Mar 18, 2021 at 10:01 comment added aProgger Maybe you should use el.innerHTML.trim() instead. In my case, <p><img ..></p> was removed aswell.
Jan 7, 2019 at 8:48 vote accept user8758206
Jan 4, 2019 at 22:57 history answered Blindman67 CC BY-SA 4.0