The 'jsrsasign' (RSA-Sign JavaScript Library) is an opensource free cryptography library supporting RSA/RSAPSS/ECDSA/DSA signing/validation, ASN.1, PKCS#1/5/8 private/public key, X.509 certificate, CRL, OCSP, CMS SignedData, TimeStamp, CAdES and JSON Web Signature/Token in pure JavaScript.
As per documentation, JWS.sign method should accept a key
The code does not support this (from jsrsasign>modules>KJUR>jws>JWS.d.ts)
Version
"jsrsasign": "^10.5.20"