[v2] Мonorepo, sdk-client, sdk-server, sdk-core package split (#1279)

This commit is contained in:
Konstantin Konstantinov 2025-12-19 15:19:02 +02:00 • committed by GitHub
commit 71ae3acee0
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -0,0 +1,7 @@
import { webcrypto } from 'node:crypto';
// Polyfill globalThis.crypto for environments (e.g. Node 18) where it is not defined.
// This is necessary for the tests to run in Node 18, specifically for the jose library, which relies on the globalThis.crypto object.
if (typeof globalThis.crypto === 'undefined') {
globalThis.crypto = webcrypto;
}