Confused about the file structure of ionic 2

I generated my project by:

ionic start demo sidemenu --v2 --ts

But I’m quite confused about these two folders: www, app.

  • Is www the result of the build? If not, why there are some duplicated files in www and app?
  • Is app the source to build the www? If this is correct, why the file in www/build folder used in for example app.ts? I mean why we use the built file instead of the source file here?

@App({ templateUrl: 'build/app.html', config: {} // http://ionicframework.com/docs/v2/api/config/Config/ })

I recommend reading through this issue, it explains why the directory structure is the way it is:

Thanks for your reply.

But it did not convince me. Based on the discussing, the build folder should be the result of the build which can be removed safely. Do you think to put a templateUrl to a generated file is elegant? Why can’t we just point the templateUrl to the source itself?

Anyway the sample is very nice. I’ll learn more from this. Thanks.