mol_wire_lib 1.0.804 → 1.0.806

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.
package/web.mjs CHANGED
@@ -1047,11 +1047,15 @@ var $;
1047
1047
  (function ($) {
1048
1048
  $.$mol_key_store = new WeakMap();
1049
1049
  function $mol_key(value) {
1050
+ if (typeof value === 'bigint')
1051
+ return value.toString() + 'n';
1050
1052
  if (!value)
1051
1053
  return JSON.stringify(value);
1052
1054
  if (typeof value !== 'object' && typeof value !== 'function')
1053
1055
  return JSON.stringify(value);
1054
1056
  return JSON.stringify(value, (field, value) => {
1057
+ if (typeof value === 'bigint')
1058
+ return value.toString() + 'n';
1055
1059
  if (!value)
1056
1060
  return value;
1057
1061
  if (typeof value !== 'object' && typeof value !== 'function')
package/web.test.js CHANGED
@@ -1218,6 +1218,7 @@ var $;
1218
1218
  $mol_assert_equal($mol_key(false), 'false');
1219
1219
  $mol_assert_equal($mol_key(true), 'true');
1220
1220
  $mol_assert_equal($mol_key(0), '0');
1221
+ $mol_assert_equal($mol_key(1n << 64n), '18446744073709551616n');
1221
1222
  $mol_assert_equal($mol_key(''), '""');
1222
1223
  },
1223
1224
  'Array & POJO'() {