Node.js just closed one of its biggest architectural gaps with Deno and Bun, and honestly, as someone who has lost a non-zero amount of life expectancy to node-gyp , I'm happy about it.
As of Node.js 26.1 (May 2026) , we finally have an experimental built-in FFI module ( node:ffi ) . π
The old ritual
Need to call a native C/C++ library?
Write a C++ addon.
Fight with binding.gyp .
Install build tools.
Discover that it works on your machine and nowhere else.
Question your career choices.
The new way
const { DynamicLibrary , suffix } = require ( ' node:ffi ' );
const lib = new DynamicLibrary ( `libsqlite3. ${ suffix } ` );
const sqlite3_libversion = lib . getFunction ( ' sqlite3_libversion ' , { result : ' string ' });
console .β¦