
ChainSafe
4.8K posts

ChainSafe
@ChainSafeth
Infrastructure and protocol development for the decentralized web. Home of the @lodestar_eth Ethereum client & Forest🌲 Filecoin client.


The EF is shrinking. Researchers are leaving. Vitalik says ETH is "the most high-value product" and CROPS is the new mandate. What does that all mean for Ethereum? @0xzak + @gregthegreek join @laurashin Today at 1 pm ET Join us on: X - x.com/Unchained_pod YouTube - youtube.com/channel/UCWiiM… or PumpFun - pump.fun/coin/GgzH3GfJa…







Livestream: youtube.com/live/ixCRYB7K_…




Zig is becoming an increasingly attractive choice for building native Node.js modules. But the JavaScript binding layer still feels stuck in 2015. Even the simplest native function requires repetitive plumbing. For every useful line of logic, you write several lines of binding code. While building native infrastructure, we kept running into this problem repeatedly inside zapi, a Zig N-API wrapper library and CLI for building and publishing cross-platform Node.js native addons. We wanted a way to preserve full control over Node's N-API when needed while dramatically simplifying the common path. The result is a new high-level DSL introduced in zapi that lets you write plain Zig functions and automatically turns them into JavaScript APIs at compile time. The DSL is already powering production bindings in lodestar-z, where we are migrating Lodestar, ChainSafe's Ethereum consensus client, from JavaScript to Zig.

