This is a simple project to demonstrate the difference between the usage of top-level await using commonJS and ES Modules in NodeJS.
Jump into the folder that you want to test out. For example,
- cd into 'ES Modules' folder through your terminal
- run node index_EMS.js
- cd into 'Common JS' folder through your terminal
- remove line 3, "type": "module", from package.json
- run node index.js