aboutsummaryrefslogtreecommitdiff
path: root/src/bun.js/scripts/class-definitions.ts
diff options
context:
space:
mode:
Diffstat (limited to 'src/bun.js/scripts/class-definitions.ts')
-rw-r--r--src/bun.js/scripts/class-definitions.ts3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/bun.js/scripts/class-definitions.ts b/src/bun.js/scripts/class-definitions.ts
index 59b8f6f05..281cd62c5 100644
--- a/src/bun.js/scripts/class-definitions.ts
+++ b/src/bun.js/scripts/class-definitions.ts
@@ -41,6 +41,7 @@ export interface ClassDefinition {
configurable?: boolean;
enumerable?: boolean;
+ structuredClone?: boolean | { transferrable: boolean; tag: number };
}
export interface CustomField {
@@ -58,6 +59,7 @@ export function define(
estimatedSize = false,
call = false,
construct = false,
+ structuredClone = false,
...rest
} = {} as ClassDefinition,
): ClassDefinition {
@@ -66,6 +68,7 @@ export function define(
call,
construct,
estimatedSize,
+ structuredClone,
values,
klass: Object.fromEntries(Object.entries(klass).sort(([a], [b]) => a.localeCompare(b))),
proto: Object.fromEntries(Object.entries(proto).sort(([a], [b]) => a.localeCompare(b))),