Configuration

Broccoli, the compilation engine we mentioned earlier, requires some configuration when adding new JavaScript and stylesheet assets.

Ember-CLI generates a configuration file named ember-cli-build.js. This file is where you can inject dependencies and configure the output structure of your application. For Tracker, you will only be adding external libraries and settings for SCSS compilation.

Open ember-cli-build.js, assign a variable to the directory path to bootstrap, and add Bootstrap’s stylesheets directory to the key includePaths in the sassOptions:

...
var EmberApp = require('ember-cli/lib/broccoli/ember-app');

module.exports = function(defaults) {

  var bootstrapPath = 'bower_components/bootstrap-sass/assets/'; var ...

Get Front-End Web Development: The Big Nerd Ranch Guide now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.