Angular Ionic应用程序,Typescript错误找不到名称';请求模式';
我的ionic应用程序有问题,在ionic&angular servicestack中进行一些更新后,会出现如下错误 Typescript错误找不到名称“RequestMode”。 节点\u模块/servicestack客户端/src/index.d.ts Typescript错误找不到名称“RequestCredentials”。 节点\u模块/servicestack客户端/src/index.d.ts 我的爱奥尼亚,角度和个人电脑信息Angular Ionic应用程序,Typescript错误找不到名称';请求模式';,angular,ionic2,
servicestack,ionic3,Angular,Ionic2,
servicestack,Ionic3,我的ionic应用程序有问题,在ionic&angular servicestack中进行一些更新后,会出现如下错误 Typescript错误找不到名称“RequestMode”。 节点\u模块/servicestack客户端/src/index.d.ts Typescript错误找不到名称“RequestCredentials”。 节点\u模块/servicestack客户端/src/index.d.ts 我的爱奥尼亚,角度和个人电脑信息 Typescript : 2.4.2 Ionic Fr
Typescript : 2.4.2
Ionic Framework: 3.1.1
Ionic App Scripts: 1.3.4
Angular Core: 4.0.2
Angular Compiler CLI: 4.0.2
Node: 6.10.0
OS Platform: macOS Sierra
Navigator Platform: MacIntel
User Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10_12_2) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/60.0.3112.90 Safari/537.36
tsconfig.json文件
{
"compilerOptions": {
"allowSyntheticDefaultImports": true,
"declaration": false,
"emitDecoratorMetadata": true,
"experimentalDecorators": true,
"target": "es5",
"module": "commonjs",
"lib": ["dom","es2015"],
"moduleResolution": "node",
"sourceMap": true
},
"include": [
"src/**/*.ts",
"typings/**/*.ts"
],
"exclude": [
"node_modules"
],
"compileOnSave": false,
"atom": {
"rewriteTsconfig": false
}
}
这是最新版本,它引用了TypeScript内置的W3C获取类型,因此如果您引用的是libdom
,您将可以访问这些缺失的类型
我不确定你的项目有什么问题,但我会调查任何可能导致类型定义冲突的问题,比如任何可能导致冲突的打字/*
Typescript : 2.4.2
Ionic Framework: 3.1.1
Ionic App Scripts: 1.3.4
Angular Core: 4.0.2
Angular Compiler CLI: 4.0.2
Node: 6.10.0
OS Platform: macOS Sierra
Navigator Platform: MacIntel
User Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10_12_2) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/60.0.3112.90 Safari/537.36
{
"compilerOptions": {
"allowSyntheticDefaultImports": true,
"declaration": false,
"emitDecoratorMetadata": true,
"experimentalDecorators": true,
"target": "es5",
"module": "commonjs",
"lib": ["dom","es2015"],
"moduleResolution": "node",
"sourceMap": true
},
"include": [
"src/**/*.ts",
"typings/**/*.ts"
],
"exclude": [
"node_modules"
],
"compileOnSave": false,
"atom": {
"rewriteTsconfig": false
}
}