npm xterm 4.1.0

latest releases: 5.0.0, 5.0.0-beta.60, 5.0.0-beta.59...
4 years ago

🚀 Features

📦 API

  • A callback can now be specified when calling Terminal.write that fires when the terminal has parsed the provided data (#2422) via @jerch. This is useful to know when the terminal state has definitely been updated after a write since writes are deferred and done in chunks to avoid locking up the web page.

    const term = new Terminal();
    term.write('hello world', () => console.log('processed'));

    We decided to use a callback-based approach here rather than promise-based since write is one of the most performance critical parts of xterm.js and it can easily be adapted into a promise:

    const p = new Promise(r => term.write('hello world', r));
  • Terminal.write and Terminal.writeln now accept an Uint8Array in addition to string (#2422) via @jerch

🐞 Bug fixes

📝 Documentation and internal improvements

  • Debug logging now logs character codes in addition to the actual string representation (#2424) via @Tyriar
  • Clean up keyboard handling logic and inaccurate comments (#2425) via @Tyriar
  • Remove redundant build step in publish Azure Pipelines job (#2427) via @Tyriar
  • Add tests for IL, DL and DCH sequences (#2431) via @Tyriar
  • Correct addon example in readme (#2437) via @kafeg
  • Fix demo on Windows (#2442) via @Tyriar
  • Upgrade to typescript 3.6 (#2447) via @Tyriar

⚠️ Deprecations

  • Terminal.writeUtf8 has been deprecated in favor of Terminal.write (#2422) via @jerch

    // deprecated
    term.writeUtf8(buffer);
    
    // recommended
    term.write(buffer);
    

📥 Addons

xterm-addon-attach

  • Updated to use Terminal.write instead of Terminal.writeUtf8 (#2422) via @jerch

🤝 Compatible addon versions

  • xterm-addon-attach@0.3.0
  • xterm-addon-fit@0.2.1
  • xterm-addon-search@0.2.1
  • xterm-addon-ligatures@0.2.1
  • xterm-addon-web-links@0.2.1
  • xterm-addon-webgl@0.2.1

Don't miss a new xterm release

NewReleases is sending notifications on new releases.