strongloop/loopback-example-full-stack — pull request #16 by bajtos (2014-05-30 07:50:58+00:00)
Title: Feature/api app cleanup

- move code out of `api/app.api.js` to `api/boot/*.js`
- add `api/app.json` and friends to configure the api app

/to @ritch please review.

I have a concern about the proposed usage of `app.json`. The main app file `app.api.js` matches the pattern used by loopback-boot when `NODE_ENV=api`. Here are few options how to address that:

1. Add a config option to `loopback-boot` to specify a different prefix for app config files, e.g. `app.api` instead of the default `app`. The config files in this project will be renamed to `app.api.json` and `app.api.local.js`.
2. Modify loopback-boot to use `.json.js` instead of `.js`, i.e. `app.local.json.js`.
3. Rename `app.api.js`, but that will break the concept of having `app.js` with the app source code and `app.json` with the app configuration.

Thoughts?