Importing

The preferred way to import xterm.js and its addons is the import statement of ES6 Modules.

⚠️ Attention! Do not forget to import the CSS stylesheet of xterm.js into your app to get it working appropriately.

Example


import { Terminal } from 'xterm';

const term = new Terminal();

term.open(document.getElementById('xterm-container'));