UNPKG

gl-react-dom

Version:

DOM implementation of gl-react, an universal React library to write and compose WebGL shaders

6 lines (5 loc) 243 B
export default (gl) => { // WEBGL_lose_context helps browser to GC the context. see https://jsfiddle.net/greweb/j9709k67/ const loseContextExt = gl.getExtension("WEBGL_lose_context"); if (loseContextExt) loseContextExt.loseContext(); };