title: How to Proxy Custom Element (Web Component)
body: <p><div class="snippet" data-lang="js" data-hide="false" data-console="true" data-babel="false">
  <div class="snippet-code">
  <pre class="snippet-code-js lang-js prettyprint-override"><code>class A extends HTMLElement {
    constructor() {
      super()
      return new Proxy(this, {})
    }
  }
  
  window.customElements.define('a-element', A)</code></pre>
  <pre class="snippet-code-html lang-html prettyprint-override"><code>&lt;a-element&gt;&lt;/a-element&gt;</code></pre>
  </div>
  </div>
  </p>
  
  <p>How can i Proxy custom element?</p>
  
  <p>When i try it:</p>
  
  <p><code>Uncaught InvalidStateError: custom element constructors must call super() first and must not return a different object</code>.</p>