这个错误是由于在 Node.js 中使用 import 语句而不是 require 语句导致的。这是因为 import 语句只能在 ECMAScript 模块中使用,而不是在 CommonJS 模块(Node.js 默认的模块系统)中使用。要解决此问题,您可以使用第三方库或将代码转换为 ECMAScript 模块。

autojs internalmodulescjsloaderjs1067 SyntaxError Cannot use import statement outside a moduleinternalmodulescjsloaderjs1067 SyntaxError Cannot use import statement outside a module throw err;

原文地址: https://www.cveoy.top/t/topic/flLW 著作权归作者所有。请勿转载和采集!

免费AI点我,无需注册和登录