Software Archive
Read-only legacy content
17061 Discussions

Build HTML5 website and Cordova from same source project

John_F_3
New Contributor I
752 Views

In 1621 I had a working project with one source from which I could produce builds for website, x-walk Android and iOS.

Version 1816 makes you choose HTML5 or HTML5+Cordova when it upgrades your project. If you choose the former, my custom plugins are not included in the x-walk build, and if you choose the later, there is not an option for building a web version.  The XDK warns you that you cannot go from HTML5+Cordova back to HTML5.

To solve this issue I have been renaming the .xdk and .xdke files back and forth after converting from the 11_bak files. It seems to work but what else could go wrong?

0 Kudos
1 Solution
Swati_S_Intel1
Employee
752 Views

Just an update, the fix for this issue will be available in the next release.

Swati

View solution in original post

0 Kudos
12 Replies
Swati_S_Intel1
Employee
752 Views

Hi John,

With an update of new project types to differentiate between web apps and cordova apps, the project can be either or. But, I see your point. I'll find out from our engineers if we can somehow make the same project work for both types. I'll get back to you as soon as I find out. Meanwhile what you are doing - changing the .xdk file is your best bet.

Thanks,

Swati

0 Kudos
Darren_G_
Beginner
752 Views

I also had a project that I wanted to use to design a mobile application, as well as deploy a webapp. After upgrade to 1816 I tried to open my project which required me to choose between HTML5 base or HTML5+cordova. I chose the latter as that was my primary development, and still wanted to use third party plugins. But now I can't see an option to build a webapp. It appears you can 'upgrade' from HTML5base to HTML5+cordova, but not the other way.

Help! I need to be able to build this for both. Can I import the code back into an HTML5 base to get the webapp option back?

0 Kudos
John_F_3
New Contributor I
752 Views

Darren, still waiting on a response from Intel.  In the meantime, keep updates you can restore from.  To keep my development moving forward, I have two sets of .xdk and .xdke to more in or out depending on the need to build HTML5 or HTML5+cordova.

0 Kudos
Darren_G_
Beginner
752 Views

I have a .xdk and a .xdke in the same folder. Are you saying one of these is the old version and one the new? I've already opened the project as and HTML5+cordova project after upgrading to 1816.

0 Kudos
Darren_G_
Beginner
752 Views

I see now that I have 11_bak files too. Are they backups prior to the upgrade?

If so, how are you renaming them and updating both sets? Developing in parallel?

0 Kudos
John_F_3
New Contributor I
752 Views

Darren, The 11_bak files (xdk and xdke) are the originals that underwent the upgrade.  Save these!  Copy and rename as .xdk and .xdke.  The XDK will ask which version to upgrade. Do each once and save the results.

0 Kudos
Darren_G_
Beginner
752 Views

Thank you! I was getting a little confused with which copies to save / how to open again to reconvert. Have managed to achieve what I wanted now. Just need to tidy the files! Seems crazy they've separated these features / don't make it easy to work in both. Hopefully they'll have a fix soon.

Thanks again

0 Kudos
John_F_3
New Contributor I
752 Views

Darren,

Maybe they are concerned you will use Cordova plugin calls in your HTML5? In any environment that would quickly be shown by testing and the Javascript log! I hope the feature comes back so we don't have to do the dance.

0 Kudos
Swati_S_Intel1
Employee
752 Views

Hello John/Darren,

I acknowledge the issue and the trouble you have to go through in changing the project files. We are evaluating a better solution, it might take some time. Thanks for your patience.

Swati

0 Kudos
Swati_S_Intel1
Employee
753 Views

Just an update, the fix for this issue will be available in the next release.

Swati

0 Kudos
John_F_3
New Contributor I
752 Views

Swati, that is good news. I'll use it as soon as available.

0 Kudos
Darren_G_
Beginner
752 Views

Good news. Thanks ;)

0 Kudos
Reply