-
Notifications
You must be signed in to change notification settings - Fork 19
FAQ
Find it on Bower and then run bower install --save thing_you_found
. Done. Modify the load order in config.coffee
if necessary.
What if it's not in Bower?
You need something that's not on Bower? Sounds dubious. Put it in vendor/scripts
or vendor/styles
and then modify config.coffee
to control the load order.
bower install --save bootstrap
In a template you can access {{env.isDevelopment}}
, {{env.isProduction}}
, and {{env.name}
.
In code you need to Environment = require 'config/environment'
and then instantiate the object env = Environment.create()
. After that, you can access env.get('isProduction')
and so on.
Enabling feature flags in Ember requires setting an ENV
variable before Ember loads. There's already a blank vendor/ember/config/before.coffee
file that's being loaded before Ember. You must be running the Canary or Beta build of Ember for feature flags to work. Install it via cake -c "canary" ember:install
. Read more on emberjs.com.
How do I use Bower?
All you need to do is run bower install --save package
. E.g. bower install --save moment
, and now you've got Moment.js in your vendor.js
.