diff --git a/components/demo/demo-snippet.js b/components/demo/demo-snippet.js index 5c86d480bda..61df488908c 100644 --- a/components/demo/demo-snippet.js +++ b/components/demo/demo-snippet.js @@ -211,7 +211,7 @@ class DemoSnippet extends LitElement { return lines.join('\n') .replace(/ class=""/g, '') // replace empty class attributes (class="") - .replace(/_[^=]*="[^"]*"/, '') // replace private reflected properties (_attr="value") + .replace(/\s+_[^\s/>"'=]*(=(?['"]).*?(?)?/g, '') // replace private reflected properties (_attr, _attr="value", but not target="_blank") .replace(/=""/g, ''); // replace empty strings for boolean attributes (="") }