Getting cannot use import statement outside a module
abrarmadi opened this issue · 1 comments
I installed "autoprefixer" and "postcss-cli" packages and added this script
"prefix:css":"postcss --use autoprefixer -b 'last 10 versions'
style/stylesheet.comp.css -o style/style.prefix.css"
to the package.json, but when I am trying to run it, I am getting the following error
SyntaxError: Cannot use import statement outside a module at Module._compile (internal/modules/cjs/loader.js:895:18) at Object.Module._extensions..js (internal/modules/cjs/loader.js:995:10) at Module.load (internal/modules/cjs/loader.js:815:32) at Function.Module._load (internal/modules/cjs/loader.js:727:14) at Function.Module.runMain (internal/modules/cjs/loader.js:1047:10) at internal/main/run_main_module.js:17:11
how can I check that postcss-cli was not moved to ESM?
postcss-cli is written with ESM; please use Node 12+