Node.js 错误TS2305:模块'&引用;readline"';没有导出的成员';接口';-火基函数
我打算部署firebase函数,但在部署时遇到了这个错误Node.js 错误TS2305:模块'&引用;readline"';没有导出的成员';接口';-火基函数,node.js,firebase,Node.js,Firebase,我打算部署firebase函数,但在部署时遇到了这个错误 ../../../../node_modules/@types/inquirer/lib/utils/screen-manager.d.ts:1:10 - error TS2305: Module '"readline"' has no exported member 'Interface'. 1 import { Interface as ReadLineInterface } from "readlin
../../../../node_modules/@types/inquirer/lib/utils/screen-manager.d.ts:1:10 - error TS2305: Module '"readline"' has no exported member 'Interface'.
1 import { Interface as ReadLineInterface } from "readline";
~~~~~~~~~
Found 15 errors.
npm ERR! code ELIFECYCLE
npm ERR! errno 2
npm ERR! functions@ build: `tsc`
npm ERR! Exit status 2
我的ts配置
{
"compilerOptions": {
"module": "commonjs",
"noImplicitReturns": true,
"noImplicitAny": false,
"noUnusedLocals": true,
"outDir": "lib",
"sourceMap": true,
"strict": true,
"target": "es2017"
},
"compileOnSave": true,
"include": [
"src"
]
}
这个错误是突然发生的,我的项目过去是正确部署的。我不知道为什么现在会这样?请告诉我此错误的根本原因是什么我解决了使用skipLibCheck选项更新ts配置的问题:
../../../../node_modules/@types/inquirer/lib/utils/screen-manager.d.ts:1:10 - error TS2305: Module '"readline"' has no exported member 'Interface'.
1 import { Interface as ReadLineInterface } from "readline";
~~~~~~~~~
Found 15 errors.
npm ERR! code ELIFECYCLE
npm ERR! errno 2
npm ERR! functions@ build: `tsc`
npm ERR! Exit status 2
"skipLibCheck": true
我希望它对你有用