Latest in Data Processing
Reading, transforming, and streaming data in Node.js — parsing large files, reshaping JSON, and handling data without exhausting memory.
Jev, TypeSafe's "System One" model, tested in Node.js: 400 support tickets, accuracy, latency, cost and calibration
Jev doesn't generate text: you send a state and typed questions, and it returns typed answers with probabilities. 400 real banking support messages were routed with TypeSafe's Node.js SDK: 92.8% accuracy, a 267 ms median, about $0.02 per 1,000 decisions, and confidence scores honest enough to decide which tickets to automate. Compared with a small local LLM, plus what the SDK's TypeScript types catch and where Jev gets it wrong.
node:sqlite: a built-in SQL database with zero dependencies
Need a database for a script, CLI, or small service? Node.js ships node:sqlite — a synchronous SQLite driver built right in. No better-sqlite3, no node-gyp, no native compile, no npm install. Here's the full API — prepared statements, transactions, and user-defined functions — verified on a real node:26-slim image.
Pretty-print JSON in JavaScript with JSON.stringify(): indentation, replacers, and what silently gets lost
JSON.stringify(value, null, 2) pretty-prints any object without a library. Here's what the other two arguments do, which values JSON silently drops or mangles (undefined, NaN, Map, Set, Date), which ones throw (BigInt, circular references), and the newer JSON.rawJSON() for numbers too big for JavaScript. All output is real, from Node 24 and 26.
Detect a user's country from their IP address in Node.js (free offline database, no API calls)
Look up a visitor's country, or city, from their IP address in Node.js using a free MMDB database and the maxmind package: about a million lookups per second, with no API key and no network calls. It also covers the validation gotcha that returns a country for garbage input, which IP to look up, and when your CDN has already done the work. Tested on Node 24 and 26.
Batch convert a folder of images to WebP and AVIF with Node.js (sharp) or FFmpeg
A ~70-line Node.js script that converts every JPG and PNG in a folder tree to WebP and AVIF with sharp — with resizing, EXIF auto-rotation, skip-if-up-to-date and parallelism, and no glob package thanks to the built-in fs.glob. Plus SVG to PNG, the FFmpeg one-liners, and the transparency gotcha that FFmpeg won't warn you about. Verified on node:24-slim and node:26-slim.
Format bytes as kB, MB and GB in JavaScript: Intl.NumberFormat, 1000 vs 1024, and the edge cases
A small, tested formatBytes() that turns 2151099283 into "2.2 GB" (or "2 GiB"), with localised output from Intl.NumberFormat. Plus why the popular Math.log one-liner prints "NaN undefined" for 0 and "1024.00 KB" for 1,048,575 bytes, and which convention (1000 or 1024) to use.