1
votes

Yes,We have resources for this on net and I searched for that ,But it didn't solve my problem so asking this question here. I have a working polymer web app and I am able to access this using http://localhost:8080//index.html,My app looks like this

enter image description here I want to deploy this app in android phone,So I used apache cordova Below are the steps I followed

  1. Installed cordova using

npm install -g cordova.

  1. create cordova project

    cordova create alertsDir com.alerts.net "Alerts" --template=C:/Users/212606402/Learning/Alert client/alert-push-notification-client

  2. cd to alertsDir and add platform

cordova platform add android

  1. build platform

cordova build android

  1. run project

cordova run android

I am not getting any error in above steps

I run this in both android emulator and nexus 5 devise but it showing the same default cordova screen,My app is not shown there,Below is the emulator screen I am seeing

enter image description here I followed some tutorials and just wondering how it works for them.

tuetorial 1 Can anyone please explain me what I am missing or doing wrong.Thanks in advance.

1
So you're building the cordova sample app and now you are wondering that shows the cordova sample app? - Phonolog
@Phonolog, Hi thanks for your reply, I am not deploying the cordova sample app, I am trying to deploy my polymer app,But in output I am getting cordova sample app. I don't know what I need to change - user3817378

1 Answers

0
votes

as far as i know, Cordova only deploy 2 folder platforms folder and www folder but not all in platforms folder will get deployed to your device, usually the cli will merge platform_www and www folder. so if you want to make a cordova app you need to put all your sourcecode or sourcecode that already bundeled using either polymer-build with gulp or polymer-cli inside www directory.