@reallyme/jose 0.3.0 → 0.3.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -22,21 +22,21 @@ export function executeOperationJson(request) {
22
22
  function __wbg_get_imports() {
23
23
  const import0 = {
24
24
  __proto__: null,
25
- __wbg___wbindgen_throw_344f42d3211c4765: function(arg0, arg1) {
25
+ __wbg___wbindgen_throw_bb96b2010945f0bc: function(arg0, arg1) {
26
26
  throw new Error(getStringFromWasm0(arg0, arg1));
27
27
  },
28
- __wbg_getRandomValues_cc7f052a444bb2ce: function() { return handleError(function (arg0, arg1) {
28
+ __wbg_getRandomValues_436a51d0629d84e1: function() { return handleError(function (arg0, arg1) {
29
29
  globalThis.crypto.getRandomValues(getArrayU8FromWasm0(arg0, arg1));
30
30
  }, arguments); },
31
- __wbg_length_1f0964f4a5e2c6d8: function(arg0) {
31
+ __wbg_length_36bd29c6848c2144: function(arg0) {
32
32
  const ret = arg0.length;
33
33
  return ret;
34
34
  },
35
- __wbg_new_from_slice_77cdfb7977362f3c: function(arg0, arg1) {
35
+ __wbg_new_from_slice_3eea173078478cfe: function(arg0, arg1) {
36
36
  const ret = new Uint8Array(getArrayU8FromWasm0(arg0, arg1));
37
37
  return ret;
38
38
  },
39
- __wbg_prototypesetcall_4770620bbe4688a0: function(arg0, arg1, arg2) {
39
+ __wbg_prototypesetcall_de8e0d9553586985: function(arg0, arg1, arg2) {
40
40
  Uint8Array.prototype.set.call(getArrayU8FromWasm0(arg0, arg1), arg2);
41
41
  },
42
42
  __wbindgen_init_externref_table: function() {
@@ -113,11 +113,15 @@ function __wbg_finalize_init(instance, module) {
113
113
 
114
114
  async function __wbg_load(module, imports) {
115
115
  if (typeof Response === 'function' && module instanceof Response) {
116
+ if (!module.ok) {
117
+ throw new Error(`failed to fetch Wasm: ${module.status} ${module.statusText} fetching '${module.url}'`);
118
+ }
119
+
116
120
  if (typeof WebAssembly.instantiateStreaming === 'function') {
117
121
  try {
118
122
  return await WebAssembly.instantiateStreaming(module, imports);
119
123
  } catch (e) {
120
- const validResponse = module.ok && expectedResponseType(module.type);
124
+ const validResponse = expectedResponseType(module.type);
121
125
 
122
126
  if (validResponse && module.headers.get('Content-Type') !== 'application/wasm') {
123
127
  console.warn("`WebAssembly.instantiateStreaming` failed because your server does not serve Wasm with `application/wasm` MIME type. Falling back to `WebAssembly.instantiate` which is slower. Original error:\n", e);
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@reallyme/jose",
3
- "version": "0.3.0",
3
+ "version": "0.3.2",
4
4
  "description": "Strict JOSE, JWT, JWS, and JWE for TypeScript through the canonical ReallyMe Rust/WASM operation contract.",
5
5
  "license": "Apache-2.0",
6
6
  "repository": {
@@ -53,10 +53,10 @@
53
53
  "test": "npm run build && node --test \"test/*.test.mjs\""
54
54
  },
55
55
  "dependencies": {
56
- "@bufbuild/protobuf": "2.12.1"
56
+ "@bufbuild/protobuf": "2.14.1"
57
57
  },
58
58
  "devDependencies": {
59
- "typescript": "5.8.3"
59
+ "typescript": "7.0.2"
60
60
  },
61
61
  "engines": {
62
62
  "node": ">=20.19.0"