Tammy Kling

Results 1 issues of Tammy Kling

如果遇到项目中严格遵守ESM规范的情况,package.json的"type": "module",tsconfig中的配置也全是ESNext,这时候用cli的build就会报错,因为框架是CommonJS规范对tsrpc.config.ts文件进行引用的,如果在严格的ESM模式下,就会报错: 错误 Must use import to load ES Module: D:\hy\object\server\tsrpc.config.ts require() of ES modules is not supported. require() of D:\hy\object\server\tsrpc.config.ts from D:\hy\object\server\node_modules\tsrpc-cli\bin.js is an ES module file as it...