Warning: file_get_contents(/data/phpspider/zhask/data//catemap/1/typescript/8.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181

Warning: file_get_contents(/data/phpspider/zhask/data//catemap/6/google-chrome/4.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Cordova 为什么Ionic不返回文件的提供程序_Cordova_Typescript_Ionic2 - Fatal编程技术网

Cordova 为什么Ionic不返回文件的提供程序

Cordova 为什么Ionic不返回文件的提供程序,cordova,typescript,ionic2,Cordova,Typescript,Ionic2,在论坛上花了很多时间之后,有什么提示: 运行时错误 0:0中出现错误,原因是:文件没有提供程序 在我的app.module.ts中: .... import { File } from '@ionic-native/file'; .... .... providers: [ StatusBar, SplashScreen, File, {provide: ErrorHandler, useClass: IonicErrorHandler} ] 在服务提供商中 @Component({

在论坛上花了很多时间之后,有什么提示:

运行时错误 0:0中出现错误,原因是:文件没有提供程序

在我的app.module.ts中:

....
import { File } from '@ionic-native/file';
....
....
  providers: [
StatusBar,
SplashScreen,
File,
{provide: ErrorHandler, useClass: IonicErrorHandler}
]
在服务提供商中

@Component({
    providers: [File]
})
应用程序启动时出现上述错误消息

做一些更新作为“离子插件添加科尔多瓦插件文件”,但没有

有什么想法吗

问候

JL

更新

npm uninstall --save @ionic-native/core
npm install --save @ionic-native/core@latest

在我的情况下,我必须按照以下命令安装文件模块:

 npm install --save @ionic-native/file