cannot use import statement outside a module node js with typescript 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