Hi. I took a Typescript project that ran under Pul...
# general
d
Hi. I took a Typescript project that ran under Pulumi 2.x and when I try to run it under Pulumi 3.x I get this error:
Copy code
import * as pulumi from "@pulumi/pulumi";
    ^^^^^^
    
    SyntaxError: Cannot use import statement outside a module
If I change back to Pulumi 2.x the code runs.
I figured it out. tsconfig.json must contain:
"module": "commonjs",
👍 1
In past versions I was able to use
"module": "ESNext"
f
seems like and es6 issue, check your babel...