#​527 — April 9, 2024

Read on the Web

zx v8.0: Google’s Way to Write Shell Scripts with Node — A long-standing way to make scripting a more pleasant experience. zx provides useful wrappers around

1
child_process

, escapes arguments and gives sensible defaults. v8.0 somehow makes zx 20x smaller, faster, makes it easier to kill processes, pass input to commands, and more. A substantial release.

Google

Build a RAG Chatbot App with MongoDB and Node.js — Embark on the RAG to Riches Developer Quest — a month of innovation, learning, and exclusive rewards awaits you. You’ll interact with AI-enhanced bots and learn how to build your own with Atlas Vector Search and Node.js. Register now!

MongoDB sponsor

The April 3 Node.js Security Releases — Includes v18.20.1 (LTS), v20.12.1 (LTS) and v21.7.2 (Current), each rolling out fixes to llhttp and Undici to tackle two HTTP related vulnerabilities.

The Node.js Project

⚠️ There’s also a set of April 9 security releases likely to land later today, if you’d prefer to wait for those.

Bun 1.1 Released with Windows Support — With the codename Bundows, the popular alternative JS runtime can now run directly on Windows 10+ (plus WSL, macOS and Linux, etc). This is a key step in Bun’s broader adoption vs Node, and even features like Bun Shell work on Windows. Node compatibility continues to improve too with support for

1
node:http2

and IPC support between Bun and Node processes.

The Bun Team

IN BRIEF:

Node.js Debugging in Chrome DevTools — If Chris didn’t know how to do it, I’m going to predict many readers don’t either, so his simple example of setting it up might be helpful 🙂

Chris Coyier

Migrating 500+ Tests from Mocha to Node.js — A quick retrospective of how the Astro team migrated more than 500 test suites from Mocha to the Node.js test runner.

Astro

Versioning Workflows with TypeScript — Learn when and how to apply versioning, then practice using our TypeScript SDK in this free, hands-on training course.

Temporal Technologies sponsor

How to Implement Rate Limiting in Express.js — A practical walk through a simple setup. A viable option against certain bots and users, though not a universal solution for DDoS or determined attackers.

Antonello Zanini

🤖 A Quick First Look at Amazon Bedrock (with Node)Amazon Bedrock is AWS’s service for working with various machine learning models. Raymond Camden

📄 Building an Article Recommendation System with Upstash, Fly and OpenAI Rishi Raj Jain

📄 Managing Node.js Processes “why I think using

1
pm2

is unnecessary and what I think should be done instead.” James Sumners

📺 Building a Modular Monolith with Fastify Matteo Molina

📄 Understanding Threads in Node.js Pavel Romanov

🛠 Code & Tools

JS-Torch: A PyTorch-Like Library for JavaScript — Python’s PyTorch is one of the gold standards amongst machine learning libraries, but this project brings some of its features directly into the JavaScript world. Early days but this could become a big deal for ML in JS?

Eduardo Leao

Flyweight: An ORM Specifically for SQLite — Some interesting ideas here, a little different to your typical ORM.

Andrew Jones

📊 Counterscale: Scalable Web Analytics You Can Run on Cloudflare — A simple web analytics tracker and dashboard that’s designed to be easy to deploy and maintain by hosting it on Cloudflare (for free too, up to a certain level).

Ben Vinegar

📰 Classifieds

📆 Using AI-powered Autofix to fix broken code – Join us on April 25th to preview Autofix and learn how we are using ML to prioritize issues and alerts.

Hookdeck: The Amazon EventBridge Alternative. Receive, authenticate, transform, filter, route, and send messages across your EDAs.

Janeway: A Node Console REPL with Object Inspection — Has some neat features including being able to look into buffers with a built-in hex viewer.

Eleven Ways

  • PGlite 0.1.2 – Lightweight Postgres packaged as WASM into a TypeScript library for the browser, Node.js, Bun and Deno.

  • VineJS 2.0 – Form data validation library for Node.js.

  • better-sqlite 9.4.5 – Neat way to use SQLite from Node and Electron (and now supporting Electron 29).

  • js-bson 6.6 – MongoDB BSON parser for Node and browsers.

    1
    Binary.toString

    and

    1
    Binary.toJSON

    now align with BSON serialization.

  • node-source-walk 7.0 – Execute a callback on every node of a source code’s AST.

  • Nightwatch.js 3.6 – Node.js end-to-end testing framework.

  • Electron Packager 29.2 – Customize and package Electron apps.

  • stream-to-it 1.0 – Convert Node streams to streaming iterables.

  • Mongoose 8.3 – MongoDB object modelling approach.

  • Octokit.js 3.2 – ‘Batteries-included’ GitHub SDK.

  • 🖼 TIFF 6.0 – Pure JS TIFF image decoder.

  • Pino 8.20 – Fast JSON-powered logging.


0 Comments

Leave a Reply

Your email address will not be published. Required fields are marked *