我正在开发使用Ionic,我面临一个奇怪的问题,在我添加了crosswalk webview插件后,我的phonegap推送插件才停止工作 .
我得到了这个“错误”,如果我们可以这样称呼它们:
ionic.cloud.min.js:6 Native: deviceready did not fire within 2000ms. This can happen when plugins are in an inconsistent state. Try removing plugins from plugins/ and reinstalling them.
cordova.js:1223 deviceready has not fired after 5 seconds.
cordova.js:1216 Channel not fired: onCordovaInfoReady
cordova.js:1216 Channel not fired: onFileSystemPathsReady
ionic.cloud.min.js:6 Ionic Insights: Device information unavailable.
index.html#/login:1 Deferred long-running timer task(s) to improve scrolling smoothness. See crbug.com/574343.
它只是不再起作用了 .
Here is my cordova plugin list:
cordova插件cordova-plugin-compat 1.0.0“Compat”cordova-plugin-console 1.0.4“控制台”cordova-plugin-crosswalk-webview 2.1.0“Crosswalk WebView Engine”cordova-plugin-device 1.1.3“设备“cordova-plugin-file 4.3.0”文件“cordova-plugin-splashscreen 4.0.0”Splashscreen“cordova-plugin-statusbar 2.2.0”StatusBar“cordova-plugin-whitelist 1.3.0”Whitelist“ionic-pluggin-keyboard 2.2.1“键盘”phonegap-plugin-push 1.9.0“PushPlugin”
离子信息
您的系统信息:Cordova CLI:6.4.0 Ionic Framework版本:1.3.1 Ionic CLI版本:2.1.4 Ionic App Lib版本:2.1.2操作系统:节点版本:v4.2.4 --------- -----------------------
所以基本上就是这样,没有crosswalk插件,phonegap推送插件可以工作,但事实并非如此 .
希望可以有人帮帮我,
谢谢!
-
-
-
-
-
-
-
-
-
-
- 编辑
-
-
-
-
-
-
-
-
-
经过一些尝试和错误后,我认为这是与使用人行横道时的范围相关的东西,因为$ ionicPush.register()没有被触发 .
使用人行横道的$ scope($ $ ionicView.beforeEnter)有什么变化?
这仍然有效或人行横道有自己的“beforeEnter”,因为他是一个不同的网络视图 .
用离子运行android附加控制台的图像:
正如你在行中看到的那样:
离子推送:已保存的推送令牌:dJYMPT2lVW8:APA91bE1UyH6qKksGykcbOFNe_HXVQPvAfSR7PJx_F_BgKIriE5sXpBGJENJS8heqQg7TAyKNAjp5sRjseEFoYIoz72DOY9VGq1-4dkKMMq6cIkhvLSBmxfKz57XBaFClEsUXpNp_zc2
令牌没有在人行横道上注册,因为没有人行横道 .
3 回答
版本2.1.0的crosswalk插件不适用于cordova-android 6.0.0(包含在cordova CLI 6.4.0中的版本)
而不是降级你可以从已经修复它的github安装crosswalk
我刚解决了我的问题,对于那些遇到与我相同问题的人,我需要将cordova降级到6.0.0并将插件推送到1.8.3 . 现在一切正常,希望这可以帮助别人 .
Cordova 6.4.0
Android平台6
phonegap-plugin-push 1.9.0
一样的问题 . 要解决这个问题,我需要将Android平台降级到5.2.2,将phongap-plugin-push降级到1.8.3 .