Paul Krill
Editor at Large

Deno boosts dependency management with JSR

news
Mar 29, 20242 mins

Deno 1.42 brings faster startups, improved Node compatibility, and support for a new open-source package registry designed for TypeScript.

shutterstock 1591493512 dinosaur roadside attraction brontosaurus T Rex clouds blue sky
Credit: The Image Party / Shutterstock

Deno 1.42, the latest release of the JavaScript, TypeScript, and WebAssembly runtime, introduces support for JSR, a new package registry for JavaScript and TypeScript. The release also improves Node and NPM compatibility and startup times.

Deno 1.42 was announced March 28. Users can upgrade in their terminal by running the deno upgrade command.

Deno 1.42 allows users to consume and publish modules to the JSR package registry directly from Deno, using the deno add and deno publish subcommands. At the same time, Deno continues to support NPM. JSR offers a modern, TypeScript-first and cross-platform-compatible registry, integrated into Deno, Deno’s developers said.

For Node.js and NPM compatibility, Deno 1.42 offers numerous improvements. The async_hooks module now supports the EventEmitterAsyncResource and AsyncLocalStorage.enterWith APIs. The crypto module adds getRandomValues(), subtle, getCipherInfo(), publicKey(), and createPublicKey() APIs, along with support for more curves in multiple APIs. The worker_threads module received a major overhaul.

Deno 1.42 also addresses an issue with deno run --check, which previously could potentially type-check part of the way through execution when encountering a statically unanalyzable dynamic import or starting a worker. Deno’s developers said this feature had a large maintenance burden, posed challenges with JSR, and potentially could result in a running application failing partway through execution. Therefore, type-checking no longer occurs after the initial type check. The developers recommend using the deno check subcommand to type check these modules.

Deno 1.42 offers a faster startup time, with a 10% improvement on Linux. Bootstrap initialization now is warmed up during snapshot time and reduced memory allocations. And a new environment variable, DENO_FUTURE=1, allows you to enable changes that will take place in Deno 2.0.

Deno 1.42 ships with the V8 12.3 JavaScript engine and TypeScript 5.4.3.

Paul Krill

Paul Krill is editor at large at InfoWorld. Paul has been covering computer technology as a news and feature reporter for more than 35 years, including 30 years at InfoWorld. He has specialized in coverage of software development tools and technologies since the 1990s, and he continues to lead InfoWorld’s news coverage of software development platforms including Java and .NET and programming languages including JavaScript, TypeScript, PHP, Python, Ruby, Rust, and Go. Long trusted as a reporter who prioritizes accuracy, integrity, and the best interests of readers, Paul is sought out by technology companies and industry organizations who want to reach InfoWorld’s audience of software developers and other information technology professionals. Paul has won a “Best Technology News Coverage” award from IDG.

More from this author