I'm using the ember-cli
to build my app, which gives me a nice app.js
file that I can server up on a static asset server. What is the most idiomatic way to allow for a separate configuration at deployment time?
For example, I might tell the consumer of my app.js
file to include an extra config.[js|json]
file which will get loaded, and the values from that file would go into the ENV
object... so that I can point the app at a different REST endpoint, for example (QA, Sandbox, Pre-release, etc) without re-compiling.
I figure there must be a way, I'm just not seeing it. I get that there is the config/environment.js
file, but that gets compiled into the dist
folder. I'm looking for something that sits next to the packaged JS. I can certainly hack something together, so I'm not looking for a hack. An ember-cli-addon
, perhaps? I figure there must be an "ember way" to do this.
I'm just not finding it :)