Skip to content

Commit 32efba0

Browse files
committed
Global Async di Module
1 parent 7a6b8cd commit 32efba0

File tree

2 files changed

+16
-0
lines changed

2 files changed

+16
-0
lines changed

async.js

+10
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
function samplePromise(){
2+
return Promise.resolve("Eko");
3+
}
4+
5+
async function run(){
6+
const name = await samplePromise();
7+
console.info(name);
8+
}
9+
10+
run();

async.mjs

+6
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
function samplePromise(){
2+
return Promise.resolve("Eko");
3+
}
4+
5+
const name = await samplePromise();
6+
console.info(name);

0 commit comments

Comments
 (0)