Using canvases on Electron (and plain Chromium I believe), when resuming from sleep the graphics card may release the texture which results in the terminal display and char atlas being corrupt. This API allows the consumer to clear the texture atlas right after resuming, atlas warm up is not done to simplify this process because the fact that atlases are shared between multiple terminals complicates this. Related microsoft/vscode#69665
xterm-addon-webgl
An addon for xterm.js that enables a WebGL-based renderer. This addon requires xterm.js v4+.
⚠️ This is an experimental addon that is missing some features and may be unstable ⚠️
Install
npm install --save xterm-addon-webgl
Usage
import { Terminal } from 'xterm';
import { WebglAddon } from 'xterm-addon-webgl';
const terminal = new Terminal();
terminal.loadAddon(new WebglAddon());
See the full API for more advanced usage.