summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--std/node/global.ts7
-rw-r--r--std/node/process.ts7
2 files changed, 14 insertions, 0 deletions
diff --git a/std/node/global.ts b/std/node/global.ts
index c889e9c8d..c877d1d53 100644
--- a/std/node/global.ts
+++ b/std/node/global.ts
@@ -1,2 +1,9 @@
+Object.defineProperty(globalThis, Symbol.toStringTag, {
+ value: "global",
+ writable: false,
+ enumerable: false,
+ configurable: true,
+});
+
// @ts-ignore
globalThis["global"] = globalThis;
diff --git a/std/node/process.ts b/std/node/process.ts
index f4bdd8686..9da41b45b 100644
--- a/std/node/process.ts
+++ b/std/node/process.ts
@@ -38,6 +38,13 @@ export const process = {
},
};
+Object.defineProperty(process, Symbol.toStringTag, {
+ enumerable: false,
+ writable: true,
+ configurable: false,
+ value: "process",
+});
+
Object.defineProperty(globalThis, "process", {
value: process,
enumerable: false,