You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Removed 'canvas' property from 'IWebGL2RenderingContext' #1050
I tried building xterm.js recently, and got the following error:
addons/xterm-addon-webgl/src/GlyphRenderer.ts:305:26 - error TS2339: Property 'canvas' does not exist on type 'IWebGL2RenderingContext'.
305 gl.viewport(0, 0, gl.canvas.width, gl.canvas.height);
Looks like the canvas property was removed as per #1029, but was that intentional? MSDN says
WebGL 2 is an extension to WebGL 1. The WebGL2RenderingContext interface implements all members of the WebGLRenderingContext interface. Some methods of the WebGL 1 context can accept additional values when used in a WebGL 2 context. You will find this info noted on the WebGL 1 reference pages.
Activity
saschanaz commentedon Jul 3, 2021
No, it was accidental. I'll take a look.
Restore WebGLRenderingContextBase#canvas
Restore WebGLRenderingContextBase#canvas (#1051)