执行npx babel-node命令报SyntaxError: Cannot use import statement outside a module解决_babel-node cannot use import statement outside a m-CSDN博客网友收藏

执行npx babel-node命令报SyntaxError: Cannot use import statement outside a module解决_babel-node cannot use import statement outside a m-CSDN博客

文章浏览阅读4k次。D:\CODE\babel模块化>npx babel-node index.jsD:\CODE\babel模块化\index.js:2import m1 from './m1.js';^^^^^^SyntaxError: Cannot use import statement outside a module?[90m at Module._compile (intern..._babel-node cannot use import statement outside a module...
阅读全文