typeson-registry 11.0.2 → 11.1.0
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/README.md +2 -0
- package/dist/index.d.ts +4 -3
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +50 -1
- package/dist/index.js.map +1 -1
- package/dist/index.min.js +1 -1
- package/dist/index.min.js.map +1 -1
- package/dist/index.umd.cjs +71 -0
- package/dist/index.umd.cjs.map +1 -1
- package/dist/index.umd.min.cjs +1 -1
- package/dist/index.umd.min.cjs.map +1 -1
- package/dist/types/promise.d.ts +6 -0
- package/dist/types/promise.d.ts.map +1 -0
- package/dist/types/promise.umd.cjs +2 -0
- package/dist/types/promise.umd.cjs.map +1 -0
- package/dist/types/symbol.d.ts +6 -0
- package/dist/types/symbol.d.ts.map +1 -0
- package/dist/types/symbol.umd.cjs +2 -0
- package/dist/types/symbol.umd.cjs.map +1 -0
- package/package.json +1 -1
package/dist/index.umd.cjs
CHANGED
|
@@ -2495,6 +2495,55 @@
|
|
|
2495
2495
|
}
|
|
2496
2496
|
};
|
|
2497
2497
|
|
|
2498
|
+
/**
|
|
2499
|
+
* @type {import('typeson').TypeSpecSet}
|
|
2500
|
+
*/
|
|
2501
|
+
var promise = {
|
|
2502
|
+
promise: {
|
|
2503
|
+
test: function test(x) {
|
|
2504
|
+
return toStringTag(x) === 'Promise';
|
|
2505
|
+
},
|
|
2506
|
+
replaceAsync: function replaceAsync(prom) {
|
|
2507
|
+
return new e( /*#__PURE__*/function () {
|
|
2508
|
+
var _ref = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee(resolve) {
|
|
2509
|
+
return _regeneratorRuntime().wrap(function _callee$(_context) {
|
|
2510
|
+
while (1) switch (_context.prev = _context.next) {
|
|
2511
|
+
case 0:
|
|
2512
|
+
_context.prev = 0;
|
|
2513
|
+
_context.t0 = resolve;
|
|
2514
|
+
_context.next = 4;
|
|
2515
|
+
return prom;
|
|
2516
|
+
case 4:
|
|
2517
|
+
_context.t1 = _context.sent;
|
|
2518
|
+
_context.t2 = {
|
|
2519
|
+
value: _context.t1
|
|
2520
|
+
};
|
|
2521
|
+
(0, _context.t0)(_context.t2);
|
|
2522
|
+
_context.next = 12;
|
|
2523
|
+
break;
|
|
2524
|
+
case 9:
|
|
2525
|
+
_context.prev = 9;
|
|
2526
|
+
_context.t3 = _context["catch"](0);
|
|
2527
|
+
resolve({
|
|
2528
|
+
error: _context.t3
|
|
2529
|
+
});
|
|
2530
|
+
case 12:
|
|
2531
|
+
case "end":
|
|
2532
|
+
return _context.stop();
|
|
2533
|
+
}
|
|
2534
|
+
}, _callee, null, [[0, 9]]);
|
|
2535
|
+
}));
|
|
2536
|
+
return function (_x) {
|
|
2537
|
+
return _ref.apply(this, arguments);
|
|
2538
|
+
};
|
|
2539
|
+
}());
|
|
2540
|
+
},
|
|
2541
|
+
revive: function revive(o) {
|
|
2542
|
+
return o.error ? Promise.reject(o.error) : Promise.resolve(o.value);
|
|
2543
|
+
}
|
|
2544
|
+
}
|
|
2545
|
+
};
|
|
2546
|
+
|
|
2498
2547
|
/**
|
|
2499
2548
|
* @type {import('typeson').TypeSpecSet}
|
|
2500
2549
|
*/
|
|
@@ -2558,6 +2607,26 @@
|
|
|
2558
2607
|
}
|
|
2559
2608
|
};
|
|
2560
2609
|
|
|
2610
|
+
/**
|
|
2611
|
+
* @type {import('typeson').TypeSpecSet}
|
|
2612
|
+
*/
|
|
2613
|
+
var symbol = {
|
|
2614
|
+
symbol: {
|
|
2615
|
+
test: function test(x) {
|
|
2616
|
+
return _typeof$1(x) === 'symbol';
|
|
2617
|
+
},
|
|
2618
|
+
replace: function replace(sym) {
|
|
2619
|
+
return {
|
|
2620
|
+
global: Symbol.keyFor(sym) !== undefined,
|
|
2621
|
+
sym: String(sym).slice(7, -1)
|
|
2622
|
+
};
|
|
2623
|
+
},
|
|
2624
|
+
revive: function revive(o) {
|
|
2625
|
+
return o.global ? Symbol["for"](o.sym) : Symbol(o.sym);
|
|
2626
|
+
}
|
|
2627
|
+
}
|
|
2628
|
+
};
|
|
2629
|
+
|
|
2561
2630
|
// Support all kinds of typed arrays (views of ArrayBuffers)
|
|
2562
2631
|
|
|
2563
2632
|
/**
|
|
@@ -3061,6 +3130,7 @@
|
|
|
3061
3130
|
exports.nonbuiltinIgnore = nonbuiltinIgnore;
|
|
3062
3131
|
exports.postmessage = postmessage;
|
|
3063
3132
|
exports.primitiveObjects = primitiveObjects;
|
|
3133
|
+
exports.promise = promise;
|
|
3064
3134
|
exports.regexp = regexp;
|
|
3065
3135
|
exports.resurrectable = resurrectable;
|
|
3066
3136
|
exports.set = set;
|
|
@@ -3070,6 +3140,7 @@
|
|
|
3070
3140
|
exports.specialNumbers = specialNumbers;
|
|
3071
3141
|
exports.structuredCloning = expObj;
|
|
3072
3142
|
exports.structuredCloningThrowing = structuredCloningThrowing;
|
|
3143
|
+
exports.symbol = symbol;
|
|
3073
3144
|
exports.toStringTag = toStringTag;
|
|
3074
3145
|
exports.typedArrays = typedArrays;
|
|
3075
3146
|
exports.typedArraysSocketio = typedArraysSocketIO;
|