Highlight search matches without touching the DOM
You add a "filter this page" box to your docs, your FAQ or a long settings screen. The user types "refund", and now you want every match to light up. The classic fix is to find the text and wrap each match in a <mark>. Then you unwrap them all on the next keystroke, and hope you…