Replies: 3 comments 2 replies
-
There is a UMD bundle available at https://cdnjs.com/libraries/jose Use that as your script src and then just drop the import * |
Beta Was this translation helpful? Give feedback.
-
thanks, tried and found that link https://cdnjs.cloudflare.com/ajax/libs/jose/5.9.6/index.bundle.min.js works without integrity checking and link https://cdnjs.cloudflare.com/ajax/libs/jose/5.9.6/index.umd.min.js seems does not export jose object and does not work. |
Beta Was this translation helpful? Give feedback.
-
The following code does not work:
|
Beta Was this translation helpful? Give feedback.
-
tried to run the following code:
<script type="module" src="https://cdnjs.cloudflare.com/ajax/libs/jose/5.9.6/index.bundle.min.js" integrity="sha512-lDE2QvY4fdlx+e8lCufg+NOzAeA3jo50Vxve53zF+ufoEUqSl6+0ArE83RlojUtc/gstniEfv3l3BsjvNGvDQg==" crossorigin="anonymous" referrerpolicy="no-referrer">
but get error as
Uncaught TypeError: Failed to resolve module specifier "jose". Relative references must start with either "/", "./", or "../".
looks like the import statement does not work (the browser can't figure out how to access jose even I use module type in script tag. May I ask if there's anything wrong in above code or if there's a jose distribution which can be used directly in plain html page.
regards
hao
Beta Was this translation helpful? Give feedback.
All reactions