# Improve the Ionic App Base template

**URL:** <https://forum.ionicframework.com/t/improve-the-ionic-app-base-template/15256>\
**Category:** ionic-v1\
**Created:** [January 7, 2015, 3:14pm UTC](https://forum.ionicframework.com/t/improve-the-ionic-app-base-template/15256 "2015-01-07T15:14:52Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![OliverSalzburg](https://sea1.discourse-cdn.com/ionicframework/user_avatar/forum.ionicframework.com/oliversalzburg/32/65797_2.png) [@OliverSalzburg](https://forum.ionicframework.com/u/OliverSalzburg)\
**Post date:** [January 7, 2015, 3:14pm UTC](https://forum.ionicframework.com/t/improve-the-ionic-app-base-template/15256/1 "2015-01-07T15:14:52Z")

</div>

After working with our app, which was built from the starter project with the Ionic CLI, I’ve recently worked on resolving the problems we had with it and I wanted to share some thoughts.

In my humble opinion, [https://github.com/driftyco/ionic-app-base](https://github.com/driftyco/ionic-app-base) has some issues and opens new users up to creating sub-optimal output.

The major reason for this is that `www` is used as the development root. `www` is the directory that will be wrapped up into the application which you deploy and distribute. Thus, you would want to keep is as slim and clean as possible. This is _not_ possible if you put all your development data (and dependencies) into it.

I understand that this is a template and that it’s up to the user to adjust it to their needs, but I don’t see why this behavior shouldn’t be avoided right from the start.

The alternative I propose is moving the user code to a different location, say `src` and putting dependencies into their default location `bower_components`. Then use gulp to “compile” the project into `www` before invoking `cordova` to build and/or deploy the app.

This has the added benefit of easily being able to include minification and, thus, reduce the size of the resulting application package. From what I can tell, this is very hard to implement with the current project structure.

I’d love to hear some thoughts on this.

---

<div class="post-metadata">

**Author:** ![CyberFerret](https://sea1.discourse-cdn.com/ionicframework/user_avatar/forum.ionicframework.com/cyberferret/32/72111_2.png) [@CyberFerret](https://forum.ionicframework.com/u/CyberFerret)\
**Post date:** [January 8, 2015, 12:16am UTC](https://forum.ionicframework.com/t/improve-the-ionic-app-base-template/15256/2 "2015-01-08T00:16:29Z")

</div>

There is some discussion on this on another thread:

> [@Improve assets setup in ionic framework](http://forum.ionicframework.com/t/improve-assets-setup-in-ionic-framework/12859/2):
>
> Hi @sformisano - I couldn’t agree more. Such a great framework with loads of features, but missing this key element. @mhartington - it would be really great if the ionic team could come up with a standardised way of doing production/dev builds and also update what is in the www folder by default when creating a new app. At the moment, the www folder is full of extra js files and sass files we don’t want copied over each time we do a build. It slows things down and increases the app size. Maybe …

It appears from the response of Ionic team members that this is a priority for them in the final release.

---

<div class="post-metadata">

**Author:** ![OliverSalzburg](https://sea1.discourse-cdn.com/ionicframework/user_avatar/forum.ionicframework.com/oliversalzburg/32/65797_2.png) [@OliverSalzburg](https://forum.ionicframework.com/u/OliverSalzburg)\
**Post date:** [January 8, 2015, 1:38am UTC](https://forum.ionicframework.com/t/improve-the-ionic-app-base-template/15256/3 "2015-01-08T01:38:00Z")

</div>

Oh, interesting. Thanks for making me aware of that.

I’d be happy to contribute, as we have a working solution for this task, based on the Ionic framework. If there’s any interest in our work, I’d appreciate a ping 🙂
