Skip to content

Latest commit

 

History

History
9 lines (6 loc) · 488 Bytes

CryptoKey.md

File metadata and controls

9 lines (6 loc) · 488 Bytes

Type Alias: CryptoKey

CryptoKey = typeof globalThis extends object ? Extract<R, { type: string; }> : CryptoKeyStructuralFallback

A Web Cryptography key as declared by the host runtime.

This aliases the key type returned by the host's SubtleCrypto.generateKey() API when it is exposed on globalThis. A structural fallback is used otherwise, keeping the package portable to runtimes and TypeScript projects that do not include DOM or Node.js ambient types.