Strip all HTML tags from a string, replacing each tag with a single space.
Uses iterative index-based scanning instead of regex to avoid polynomial backtracking (CodeQL js/polynomial-redos).
js/polynomial-redos
HTML string to strip
The text content with tags replaced by spaces
Strip all HTML tags from a string, replacing each tag with a single space.
Uses iterative index-based scanning instead of regex to avoid polynomial backtracking (CodeQL
js/polynomial-redos).