Grunt platform:add:android uses www folder instead of app floder

I have gone through https://github.com/diegonetto/generator-ionic to create a project called ‘myproj’ with below commands

>md myproj
>cd myproj
>yo ionic (used sideMenu template)
>grunt serve (Works good; Opens app in browser)
>grunt platform:add:android
>grunt emulate:android

The problem is this emulates the myproj/www folder app instead of myproj/app folder app. What’s the puprose of www folder when we have all app code in app folder?

Also when I delete myproj/www folder and runs grunt platform:add:android , it gives me an error “Current working directory is not a Cordova-based project.”

Before you emulate it, you need to build it.

>grunt build:android

This command will build your project, and copy the files from /app to /www for deployment.

1 Like