summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--bench_util/src/js_runtime.rs4
-rw-r--r--core/core.js3
-rw-r--r--op_crates/crypto/01_crypto.js1
-rw-r--r--op_crates/url/benches/url_ops.rs7
-rw-r--r--op_crates/web/02_event.js1
-rw-r--r--op_crates/web/03_abort_signal.js1
-rw-r--r--op_crates/web/04_global_interfaces.js1
-rw-r--r--op_crates/web/08_text_encoding.js1
-rw-r--r--op_crates/web/12_location.js1
-rw-r--r--runtime/js/00_bootstrap_namespace.js10
10 files changed, 3 insertions, 27 deletions
diff --git a/bench_util/src/js_runtime.rs b/bench_util/src/js_runtime.rs
index 0752e2097..a19eccd1f 100644
--- a/bench_util/src/js_runtime.rs
+++ b/bench_util/src/js_runtime.rs
@@ -8,10 +8,6 @@ use crate::profiling::is_profiling;
pub fn create_js_runtime(setup: impl FnOnce(&mut JsRuntime)) -> JsRuntime {
let mut rt = JsRuntime::new(Default::default());
- // Setup bootstrap namespace
- rt.execute("bootstrap", "globalThis.__bootstrap = {};")
- .unwrap();
-
// Caller provided setup
setup(&mut rt);
diff --git a/core/core.js b/core/core.js
index fd9b2c3ea..e5998fbc8 100644
--- a/core/core.js
+++ b/core/core.js
@@ -124,6 +124,9 @@
opSync("op_close", rid);
}
+ // Provide bootstrap namespace
+ window.__bootstrap = {};
+ // Extra Deno.core.* exports
Object.assign(window.Deno.core, {
opAsync,
opSync,
diff --git a/op_crates/crypto/01_crypto.js b/op_crates/crypto/01_crypto.js
index 12f4f45cc..dba6b0091 100644
--- a/op_crates/crypto/01_crypto.js
+++ b/op_crates/crypto/01_crypto.js
@@ -44,7 +44,6 @@
window.crypto = {
getRandomValues,
};
- window.__bootstrap = window.__bootstrap || {};
window.__bootstrap.crypto = {
getRandomValues,
};
diff --git a/op_crates/url/benches/url_ops.rs b/op_crates/url/benches/url_ops.rs
index 8d5498540..18b2f300e 100644
--- a/op_crates/url/benches/url_ops.rs
+++ b/op_crates/url/benches/url_ops.rs
@@ -10,13 +10,6 @@ fn create_js_runtime() -> JsRuntime {
..Default::default()
});
- runtime
- .execute(
- "bootstrap",
- "globalThis.__bootstrap = (globalThis.__bootstrap || {});",
- )
- .unwrap();
-
runtime.init_extension_js().unwrap();
runtime.init_extension_ops().unwrap();
diff --git a/op_crates/web/02_event.js b/op_crates/web/02_event.js
index ac813d091..35112132e 100644
--- a/op_crates/web/02_event.js
+++ b/op_crates/web/02_event.js
@@ -1202,7 +1202,6 @@
window.dispatchEvent = EventTarget.prototype.dispatchEvent;
window.addEventListener = EventTarget.prototype.addEventListener;
window.removeEventListener = EventTarget.prototype.removeEventListener;
- window.__bootstrap = (window.__bootstrap || {});
window.__bootstrap.eventTarget = {
EventTarget,
setEventTargetData,
diff --git a/op_crates/web/03_abort_signal.js b/op_crates/web/03_abort_signal.js
index b87a56ce3..e2648e778 100644
--- a/op_crates/web/03_abort_signal.js
+++ b/op_crates/web/03_abort_signal.js
@@ -120,7 +120,6 @@
window.AbortSignal = AbortSignal;
window.AbortController = AbortController;
- window.__bootstrap = window.__bootstrap || {};
window.__bootstrap.abortSignal = {
add,
signalAbort,
diff --git a/op_crates/web/04_global_interfaces.js b/op_crates/web/04_global_interfaces.js
index f6846d1cd..c3181fb66 100644
--- a/op_crates/web/04_global_interfaces.js
+++ b/op_crates/web/04_global_interfaces.js
@@ -44,7 +44,6 @@
}
}
- window.__bootstrap = (window.__bootstrap || {});
window.__bootstrap.globalInterfaces = {
DedicatedWorkerGlobalScope,
Window,
diff --git a/op_crates/web/08_text_encoding.js b/op_crates/web/08_text_encoding.js
index c84d7c18e..7e7d4a573 100644
--- a/op_crates/web/08_text_encoding.js
+++ b/op_crates/web/08_text_encoding.js
@@ -4559,7 +4559,6 @@
window.TextDecoder = TextDecoder;
window.atob = atob;
window.btoa = btoa;
- window.__bootstrap = window.__bootstrap || {};
window.__bootstrap.encoding = { decode };
window.__bootstrap.base64 = base64;
})(this);
diff --git a/op_crates/web/12_location.js b/op_crates/web/12_location.js
index 6c99bc23a..2b6580f8b 100644
--- a/op_crates/web/12_location.js
+++ b/op_crates/web/12_location.js
@@ -348,7 +348,6 @@
workerLocation = new WorkerLocation(href, locationConstructorKey);
}
- window.__bootstrap = (window.__bootstrap || {});
window.__bootstrap.location = {
locationConstructorDescriptor: {
value: Location,
diff --git a/runtime/js/00_bootstrap_namespace.js b/runtime/js/00_bootstrap_namespace.js
deleted file mode 100644
index d10360974..000000000
--- a/runtime/js/00_bootstrap_namespace.js
+++ /dev/null
@@ -1,10 +0,0 @@
-// Copyright 2018-2021 the Deno authors. All rights reserved. MIT license.
-
-// The only purpose of this file is to set up "globalThis.__bootstrap" namespace,
-// that is used by scripts in this directory to reference exports between
-// the files.
-
-// This namespace is removed during runtime bootstrapping process.
-"use strict";
-
-globalThis.__bootstrap = globalThis.__bootstrap || {};