科尔多瓦运行--debug建设空白应用 [英] Cordova run --debug building blank app
问题描述
我已经建立了与离子的应用程序。当我使用PhoneGap的桌面程序在服务器上运行它,查看我的手机上会显示应用程序正确但是当我运行
离子平台添加的android
离子构建Android
平台\\机器人\\科尔多瓦\\运行--debug
这将启动与闪烁设备平原科尔多瓦程序已经准备好
和标题的Apache Cordova
。该应用程序p>
这是真的很烦,因为我不明白发生什么事,怎么会这样,即使发生。我建立了正确的解决方案,但安装的APK是完全不同的东西。我甚至不具有dislays,在我的项目文件的视图!!!!
修改我刚发现的东西完全出乎意料。在平台\\机器人\\资产\\ WWW
中的文件是原始科尔多瓦空白的应用程序(我在设备查看视图),但在我的应用程序 WWW
文件夹中的文件完全。我的猜测是,科尔多瓦构建Android
是不是真的建设的正确应用。可能是什么这个原因,我该如何解决?
EDIT2
如果我复制我的〜/ WWW
内容平台\\机器人\\资产\\ WWW
然后它会呈现正确的细节。我仍然困惑,为什么科尔多瓦版本不正确的资产文件复制到相应目录
EDIT3 如果别人遇到了同样的问题需要注意,科尔多瓦没有复制或 WWW
文件夹编制的任何文件。这也适用于插件了。为了安装插件,你必须做到:
科尔多瓦插件添加<插件,名称>
我不知道为什么会这样。这可能是值得打开票,科尔多瓦队来解决这个问题。
我有同样的问题。周围有点挖后,从离子论坛有人建议一种变通方法 - 降级节点4.2.2。它为我工作!
I've built an app with ionic. When I use phonegap desktop program to run it on a server and view it on my phone it displays the app correctly however when I run
ionic platform add android
ionic build android
platforms\android\cordova\run --debug
The app which launches is the plain cordova app with blinking device is ready
and title APACHE CORDOVA
.
This is really annoying since I don't understand what is happening and how could this even happen. I am building the correct solution but the installed apk is something totally different. I don't even have a view that dislays that in my project files!!!!
EDIT I just found something completely unexpected. In platforms\android\assets\www
the files are the original cordova blank app (the view that I see in device) but in my app www
folder the files are totally. My guess is that cordova build android
is not really building the correct app. What could be the cause of this and how can I fix it?
EDIT2
If I copy my ~/www
content to platforms\android\assets\www
then it will render the correct details. I'm still confused as to why cordova build does not copy the correct asset files to the relevant directory
EDIT3 If anyone else is experiencing the same problem take note that cordova is not copying or compiling any of the files in www
folders. That goes for the plugins too. In order to install plugins you must do:
cordova plugin add <plugin-name>
I am not aware of why this happens. It might be worth opening a ticket for the cordova team to fix this issue.
I was having the same issue. After digging around a bit, someone from the Ionic Forum suggested a workaround - downgrading Node to 4.2.2. It worked for me!
这篇关于科尔多瓦运行--debug建设空白应用的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!