typesccript SyntaxError: Cannot use import statement outside a module code example
Example: cannot use import statement outside a module typescript
// Fix 1
Change .js files to .cjs
// Fix 2
Add "type": "module" to package.json
// Fix 1
Change .js files to .cjs
// Fix 2
Add "type": "module" to package.json