aboutsummaryrefslogtreecommitdiff
path: root/integration/bunjs-only-snippets
diff options
context:
space:
mode:
authorGravatar Jarred Sumner <709451+Jarred-Sumner@users.noreply.github.com> 2022-06-07 22:42:12 -0700
committerGravatar Jarred Sumner <709451+Jarred-Sumner@users.noreply.github.com> 2022-06-07 22:42:12 -0700
commit5b4dcb8d169f0463df83624a25b004636f3516d9 (patch)
treeca90187af3b4a8a8bb314bbc0d412f79681ab2e8 /integration/bunjs-only-snippets
parentcdd1a2bdc09105e9be0947c8c7990b1a7c737611 (diff)
downloadbun-5b4dcb8d169f0463df83624a25b004636f3516d9.tar.gz
bun-5b4dcb8d169f0463df83624a25b004636f3516d9.tar.zst
bun-5b4dcb8d169f0463df83624a25b004636f3516d9.zip
log esm import order
Diffstat (limited to 'integration/bunjs-only-snippets')
-rw-r--r--integration/bunjs-only-snippets/esm/first.mjs8
-rw-r--r--integration/bunjs-only-snippets/esm/second-child.mjs5
-rw-r--r--integration/bunjs-only-snippets/esm/second.mjs7
-rw-r--r--integration/bunjs-only-snippets/esm/startEnd.mjs6
-rw-r--r--integration/bunjs-only-snippets/esm/third.mjs4
5 files changed, 30 insertions, 0 deletions
diff --git a/integration/bunjs-only-snippets/esm/first.mjs b/integration/bunjs-only-snippets/esm/first.mjs
new file mode 100644
index 000000000..17021c623
--- /dev/null
+++ b/integration/bunjs-only-snippets/esm/first.mjs
@@ -0,0 +1,8 @@
+import { end, start } from "./startEnd.mjs";
+
+start("First");
+
+import "./second.mjs";
+import "./third.mjs";
+
+end("First");
diff --git a/integration/bunjs-only-snippets/esm/second-child.mjs b/integration/bunjs-only-snippets/esm/second-child.mjs
new file mode 100644
index 000000000..5fb06ed45
--- /dev/null
+++ b/integration/bunjs-only-snippets/esm/second-child.mjs
@@ -0,0 +1,5 @@
+import { start, end } from "./startEnd.mjs";
+
+start("Second (nested import)");
+
+end("Second (nested import)");
diff --git a/integration/bunjs-only-snippets/esm/second.mjs b/integration/bunjs-only-snippets/esm/second.mjs
new file mode 100644
index 000000000..888eb11b9
--- /dev/null
+++ b/integration/bunjs-only-snippets/esm/second.mjs
@@ -0,0 +1,7 @@
+import { start, end } from "./startEnd.mjs";
+
+start("Second");
+
+import "./second-child.mjs";
+
+end("Second");
diff --git a/integration/bunjs-only-snippets/esm/startEnd.mjs b/integration/bunjs-only-snippets/esm/startEnd.mjs
new file mode 100644
index 000000000..8b5549802
--- /dev/null
+++ b/integration/bunjs-only-snippets/esm/startEnd.mjs
@@ -0,0 +1,6 @@
+export function start(name) {
+ console.log(`[start] ${name}`);
+}
+export function end(name) {
+ console.log(`[end] ${name}`);
+}
diff --git a/integration/bunjs-only-snippets/esm/third.mjs b/integration/bunjs-only-snippets/esm/third.mjs
new file mode 100644
index 000000000..f5ba5cc84
--- /dev/null
+++ b/integration/bunjs-only-snippets/esm/third.mjs
@@ -0,0 +1,4 @@
+import { end, start } from "./startEnd.mjs";
+
+start("Third");
+end("Third");