8000 Use import in CommonJS module · HowProgrammingWorks/Modularity@0629d4a · GitHub
[go: up one dir, main page]

Skip to content

Commit 0629d4a

Browse files
committed
Use import in CommonJS module
1 parent 6b5e9fd commit 0629d4a

File tree

1 file changed

+8
-0
lines changed

1 file changed

+8
-0
lines changed

JavaScript/b-common.js

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
'use strict';
2+
3+
const promise = import('events');
4+
console.log({ promise });
5+
6+
promise.then((events) => {
7+
console.log({ defaultMaxListeners: events.defaultMaxListeners });
8+
});

0 commit comments

Comments
 (0)
0