You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
This is a maintenance release that modernizes the build toolchain and runtime support. There are no changes to behavior or the public API, base64url encoding and decoding just got faster. The only reason this is a major release is the switch to an ESM-only package and a higher minimum Node.js version.
Upgrade time: minutes
Complexity: low
Risk: low (high only if you require() the module or run Node < 22)
Dependencies:@hapi/hoek 12 (ESM-only)
Breaking changes
ESM-only. The package is now only shipping ESM, CommonJS is no longer supported.
Node.js >= 22 required (previously >= 14). Older runtimes are no longer supported.
New features
TypeScript types are now built in, @types/hapi__b64 is no longer needed.
Faster base64url.base64urlEncode() and base64urlDecode() now use Node's native 'base64url' encoding, with the same output as before (Use node base64url option #43).
Bug fixes
None.
Migration checklist
ESM-only and Node.js >= 22
We are cutting support at the latest Node.js LTS. While it may work on older versions of Node.js such as 20+ which supports require-ing ESM, we cannot guarantee it will stay that way.
TypeScript types
Remove @types/hapi__b64 from your dependencies. The built-in types have the same signatures, so no code change is needed.
Activity