typeson-registry 14.2.2 → 14.3.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/dist/index.d.ts +2 -1
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +24 -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 +22 -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/polyfills/DOMMatrix.d.ts +2 -2
- package/dist/polyfills/DOMMatrix.d.ts.map +1 -1
- package/dist/polyfills/DOMMatrixReadOnly.d.ts +2 -2
- package/dist/polyfills/DOMMatrixReadOnly.d.ts.map +1 -1
- package/dist/presets/structured-cloning-for-storage.d.ts +6 -0
- package/dist/presets/structured-cloning-for-storage.d.ts.map +1 -0
- package/dist/presets/structured-cloning-for-storage.umd.cjs +4 -0
- package/dist/presets/structured-cloning-for-storage.umd.cjs.map +1 -0
- package/package.json +1 -1
- package/polyfills/DOMMatrix.js +2 -2
- package/polyfills/DOMMatrixReadOnly.js +2 -2
- package/polyfills/index.cjs +6 -4
- package/polyfills/index.cjs.map +1 -1
package/dist/index.d.ts
CHANGED
|
@@ -47,9 +47,10 @@ import postmessage from './presets/postmessage.js';
|
|
|
47
47
|
import socketio from './presets/socketio.js';
|
|
48
48
|
import sparseUndefined from './presets/sparse-undefined.js';
|
|
49
49
|
import specialNumbers from './presets/special-numbers.js';
|
|
50
|
+
import structuredCloningForStorage from './presets/structured-cloning-for-storage.js';
|
|
50
51
|
import structuredCloningThrowing from './presets/structured-cloning-throwing.js';
|
|
51
52
|
import structuredCloning from './presets/structured-cloning.js';
|
|
52
53
|
import undefPreset from './presets/undef.js';
|
|
53
54
|
import universal from './presets/universal.js';
|
|
54
|
-
export { arraybuffer, audiodata, bigintObject, bigint, blob, cloneable, cryptokey, dataview, date, domexception, dommatrix, dompoint, domquad, domrect, encodedaudiochunk, encodedvideochunk, error, errors, file, filelist, imagebitmap, imagedata, infinity, intlTypes, map, nan, negativeInfinity, negativeZero, nonbuiltinIgnore, primitiveObjects, promise, quotaexceedederror, regexp, resurrectable, set, symbol, typedArraysSocketio, typedArrays, undef, userObject, videoframe, webtransporterror, arrayNonindexKeys, builtin, postmessage, socketio, sparseUndefined, specialNumbers, structuredCloningThrowing, structuredCloning, undefPreset, universal };
|
|
55
|
+
export { arraybuffer, audiodata, bigintObject, bigint, blob, cloneable, cryptokey, dataview, date, domexception, dommatrix, dompoint, domquad, domrect, encodedaudiochunk, encodedvideochunk, error, errors, file, filelist, imagebitmap, imagedata, infinity, intlTypes, map, nan, negativeInfinity, negativeZero, nonbuiltinIgnore, primitiveObjects, promise, quotaexceedederror, regexp, resurrectable, set, symbol, typedArraysSocketio, typedArrays, undef, userObject, videoframe, webtransporterror, arrayNonindexKeys, builtin, postmessage, socketio, sparseUndefined, specialNumbers, structuredCloningForStorage, structuredCloningThrowing, structuredCloning, undefPreset, universal };
|
|
55
56
|
//# sourceMappingURL=index.d.ts.map
|
package/dist/index.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../index.js"],"names":[],"mappings":";wBAGwB,wBAAwB;sBAC1B,sBAAsB;yBACnB,0BAA0B;mBAChC,mBAAmB;iBACrB,iBAAiB;sBACZ,sBAAsB;sBACtB,sBAAsB;qBACvB,qBAAqB;iBACzB,iBAAiB;yBACT,yBAAyB;sBAC5B,sBAAsB;qBACvB,qBAAqB;oBACtB,oBAAoB;oBACpB,oBAAoB;8BACV,8BAA8B;8BAC9B,8BAA8B;kBAC1C,kBAAkB;mBACjB,mBAAmB;iBACrB,iBAAiB;qBACb,qBAAqB;wBAClB,wBAAwB;sBAC1B,sBAAsB;qBACvB,qBAAqB;sBACpB,uBAAuB;gBAC7B,gBAAgB;gBAChB,gBAAgB;6BACH,8BAA8B;yB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AwB"}
|
package/dist/index.js
CHANGED
|
@@ -2170,6 +2170,29 @@ const structuredCloningThrowing = expObj.concat({
|
|
|
2170
2170
|
}
|
|
2171
2171
|
});
|
|
2172
2172
|
|
|
2173
|
+
/**
|
|
2174
|
+
* @type {import('typeson').Preset}
|
|
2175
|
+
*/
|
|
2176
|
+
const structuredCloningForStorage = structuredCloningThrowing.concat({
|
|
2177
|
+
checkSharedArrayBufferException: {
|
|
2178
|
+
test (val) {
|
|
2179
|
+
// Per https://webidl.spec.whatwg.org/#idl-SharedArrayBuffer ,
|
|
2180
|
+
// `SharedArrayBuffer` is a structured-cloneable *transferable*
|
|
2181
|
+
// type only for `postMessage`-style contexts (with
|
|
2182
|
+
// `crossOriginIsolated`); storage-oriented consumers of the
|
|
2183
|
+
// structured clone algorithm (e.g. IndexedDB) reject it
|
|
2184
|
+
// outright instead, so this isn't part of the more general
|
|
2185
|
+
// `structuredCloningThrowing` preset this one builds on.
|
|
2186
|
+
if (({}.toString.call(val).slice(8, -1)) === 'SharedArrayBuffer') {
|
|
2187
|
+
throw new DOMException(
|
|
2188
|
+
'The object cannot be cloned.', 'DataCloneError'
|
|
2189
|
+
);
|
|
2190
|
+
}
|
|
2191
|
+
return false;
|
|
2192
|
+
}
|
|
2193
|
+
}
|
|
2194
|
+
});
|
|
2195
|
+
|
|
2173
2196
|
/**
|
|
2174
2197
|
* @type {import('typeson').Preset}
|
|
2175
2198
|
*/
|
|
@@ -2187,5 +2210,5 @@ const universal = [
|
|
|
2187
2210
|
// built-in into ecmasript standard.
|
|
2188
2211
|
];
|
|
2189
2212
|
|
|
2190
|
-
export { i$1 as JSON_TYPES, Typeson, TypesonPromise, Undefined, arrayNonindexKeys, arraybuffer, audiodata, bigint, bigintObject, blob, expObj$1 as builtin, cloneable, cryptokey, dataview, date, domexception, dommatrix, dompoint, domquad, domrect, encodedaudiochunk, encodedvideochunk, error, errors, escapeKeyPathComponent, file, filelist, getByKeyPath, getJSONType, hasConstructorOf, imagebitmap, imagedata, infinity, intlTypes, isObject, isPlainObject, isThenable, isUserObject, map, nan, negativeInfinity, negativeZero, nonbuiltinIgnore, postmessage, primitiveObjects, promise, quotaexceedederror, regexp, resurrectable, set, setAtKeyPath, socketio, sparseUndefined, specialNumbers, expObj as structuredCloning, structuredCloningThrowing, symbol, toStringTag, typedArrays, typedArraysSocketIO as typedArraysSocketio, undef$1 as undef, undef as undefPreset, unescapeKeyPathComponent, universal, userObject, videoframe, webtransporterror };
|
|
2213
|
+
export { i$1 as JSON_TYPES, Typeson, TypesonPromise, Undefined, arrayNonindexKeys, arraybuffer, audiodata, bigint, bigintObject, blob, expObj$1 as builtin, cloneable, cryptokey, dataview, date, domexception, dommatrix, dompoint, domquad, domrect, encodedaudiochunk, encodedvideochunk, error, errors, escapeKeyPathComponent, file, filelist, getByKeyPath, getJSONType, hasConstructorOf, imagebitmap, imagedata, infinity, intlTypes, isObject, isPlainObject, isThenable, isUserObject, map, nan, negativeInfinity, negativeZero, nonbuiltinIgnore, postmessage, primitiveObjects, promise, quotaexceedederror, regexp, resurrectable, set, setAtKeyPath, socketio, sparseUndefined, specialNumbers, expObj as structuredCloning, structuredCloningForStorage, structuredCloningThrowing, symbol, toStringTag, typedArrays, typedArraysSocketIO as typedArraysSocketio, undef$1 as undef, undef as undefPreset, unescapeKeyPathComponent, universal, userObject, videoframe, webtransporterror };
|
|
2191
2214
|
//# sourceMappingURL=index.js.map
|