ES.nextNews: the latest in JavaScript and cross-platform tools
Curated by Dr. Axel Rauschmayer and Johannes Weber.

ES.next News

The latest in JavaScript and cross-platform tools

Prettier 2.7: new --cache CLI option and TypeScript 4.7 syntax
prettier.io@__sosukesuzuki, @PrettierCode
Highlights – quoting the blog post:
  • This release includes a new --cache CLI option. Enabling this option will use some attributes as cache keys and format files only if they have changed. This could dramatically improve CLI performance.
  • We’ve also added support for formatting TypeScript 4.7 syntax!


Deno 1.23: no type-checking by default (deno run, deno eval, deno cache) and more
deno.com@biwanczuk, @davidsherret, github/ry, @kt3k, @satyarohith_, @deno_land
  • No type-checking by default in deno run, deno eval, and deno cache
  • File watcher watches dynamic imports
  • Updates to deno task
  • Updates to deno fmt
  • deno info supports --config and --no-config flags
  • REPL: Use Ctrl-S to insert newlines into your input
  • SIGINT and SIGBREAK signal listening support on Windows
  • Support for "deflate-raw" in CompressionStream and DecompressionStream
  • TypeScript 4.7
  • Changes to flags standard module (which parses command line arguments)
  • Changes to assertThrows and assertRejects


Add 90+ code assists and refactorings to Visual Studio Code
marketplace.visualstudio.com Sponsor
Refactor JavaScript, TypeScript, React and Vue.js code. With the P42 JavaScript Assistant.


Using web streams on Node.js
2ality.com@2ality
Web streams are a new standard that works on browsers, Node.js and Deno. For example, the Response returned by fetch() has a property .body with a web stream.

The blog post is a tutorial for using web streams with many code examples. It focuses on Node.js but most of the content also applies to other platforms.



The JavaScript block statement
www.webpro.nl@webprolific
Nested block statements enable you to reuse variable names. Which can be helpful – e.g. in tests and in consoles:
function test() {
  const type = 'some';
  {
    const thing = getThing(type, 1);
    assert.equal(thing, 1);
  }
  {
    const thing = getThing(type, 2);
    assert.equal(thing, 2);
  }
}


Use esm-import-transformer for “isomorphic-ish” ECMAScript modules
www.zachleat.com@zachleat
The utility esm-import-transformer lets you search and replace module specifiers in JavaScript source code. One use case is to translate code for Node.js to code that works on browsers:
// Before
import {html, css, LitElement} from "lit";
// After
import {html, css, LitElement} from "https://cdn.jsdelivr.net/gh/lit/dist@2/core/lit-core.min.js";



Looking for deeply qualified employees or customers? Advertise on ES.next News!
ES.next News reaches over 14,000 highly skilled and motivated developers. We take their trust seriously and have high editorial standards.
Check out our media data and get directly in touch with us.
Follow on Twitter

This email was sent to {{ email | default }}. Want to change how you receive these emails?
You can unsubscribe from this list