Your pattern and test string stay in this browser tab — nothing is uploaded or stored. Matches are rendered as plain React text nodes, never as raw HTML, so untrusted test strings cannot inject markup or scripts. Without the g flag only the first match is reported, which is how the JavaScript engine itself behaves.