mswjs / interceptors

Low-level network interception library.
https://npm.im/@mswjs/interceptors
MIT License
527 stars 119 forks source link

fix: use global "crypto.randomUUID()" #530

Closed kettanaito closed 3 months ago

kettanaito commented 3 months ago
kettanaito commented 3 months ago

crypto global

crypto has become global since Node v21. In v18, it's still behind the experimental flag (although REPL loads it as global, which is somewhat confusing).

We will use a shim on the bundler level to inject crypto from node:crypto and to have the source code referencing the crypto global everywhere. Once we migrate to v20+ as the minimal supported, we can drop the shim without touching the source.

kettanaito commented 3 months ago

Released: v0.26.12 🎉

This has been released in v0.26.12!

Make sure to always update to the latest version (npm i @mswjs/interceptors@latest) to get the newest features and bug fixes.


Predictable release automation by @ossjs/release.