summaryrefslogtreecommitdiff
path: root/tests/034_onload/main.ts
diff options
context:
space:
mode:
Diffstat (limited to 'tests/034_onload/main.ts')
-rw-r--r--tests/034_onload/main.ts14
1 files changed, 14 insertions, 0 deletions
diff --git a/tests/034_onload/main.ts b/tests/034_onload/main.ts
new file mode 100644
index 000000000..68851950a
--- /dev/null
+++ b/tests/034_onload/main.ts
@@ -0,0 +1,14 @@
+import "./imported.ts";
+
+window.addEventListener(
+ "load",
+ (e: Event): void => {
+ console.log(`got ${e.type} event in event handler (main)`);
+ }
+);
+
+window.onload = (e: Event): void => {
+ console.log(`got ${e.type} event in onload function`);
+};
+
+console.log("log from main");