UNPKG

jose

Version:

JWA, JWS, JWE, JWT, JWK, JWKS for Node.js, Browser, Cloudflare Workers, Deno, Bun, and other Web-interoperable runtimes

9 lines (8 loc) 220 B
import { isCryptoKey } from './webcrypto.js'; export default (key) => { if (isCryptoKey(key)) { return true; } return key?.[Symbol.toStringTag] === 'KeyObject'; }; export const types = ['CryptoKey'];