title: Suppressing the "Rats! WebGL hit a snag." error bar in Google Chrome
body: <p>I've recently started using WebGL on a site I'm developing. It's being used as an enhancement, and the site falls back to a canvas rendering if WebGL is not supported or has an error.</p>
  
  <p>Unfortunately when a WebGL exception occurs in Google Chrome, an error message bar appears. This bar does not disappear until the user interacts with it. If they reload or navigate to a different page, the message will re-appear the next time the site tries to use WebGL.</p>
  
  <blockquote>
    <p><img src="https://i.stack.imgur.com/fvlvs.png" alt="" title="Rats! WebGL hit a snag."></p>
  </blockquote>
  
  <p>In the case of my site, this means that the WebGL error message will never go away because each page attempts to use WebGL. Once an error has occurred Chrome will not use WebGL again on the same site until the user tells it to <em>Reload</em>, so the continuous error message doesn't actually indicate continuous errors, just continuous attempts to use WebGL.</p>
  
  <hr>
  
  <p>Once a WebGL error occurs, this dialog can be reproduced on that site just by running:</p>
  
  <pre><code>document.createElement('canvas').getContext('experimental-webgl');
  </code></pre>
  
  <p>This does not raise any exception, and my <code>.onerror</code> method on the canvas element wasn't called.</p>
  
  <p>I haven't been able to investigate this too deeply because I have not been able to reliably reproduce a WebGL error. (Even if I could reproduce one on my computer, it may not be reproducible on others.)</p>
  
  <hr>
  
  <p>This behaviour would be reasonable for a site that relied on WebGL, but mine does not, so the message is just distracting and confusing to users.</p>
  
  <p>Is there any way to suppress this error message? I don't mind falling back to the <em>Ignore</em> behaviour of having WebGL disabled once an error occurs.</p>