
Security News
CVE Volume Surges Past 48,000 in 2025 as WordPress Plugin Ecosystem Drives Growth
CVE disclosures hit a record 48,185 in 2025, driven largely by vulnerabilities in third-party WordPress plugins.
ember-cli-fastboot-addon
Advanced tools
Provides facilities for writing code that works in both Fastboot and the browser.
ember install ember-cli-fastboot-addon
Addons require a little more setup. If you're just using this in your app, you can move to the next step.
You need to use the Broccoli filter in your addon. In index.js:
module.exports = {
name: 'my-addon',
treeForAddon: function(tree) {
var fastbootTree = require('ember-cli-fastboot-addon').fastbootTree;
return this._super.treeForAddon.call(this, fastbootTree(tree));
},
treeForApp: function(tree) {
var fastbootTree = require('ember-cli-fastboot-addon').fastbootTree;
return fastbootTree(tree);
}
}
After running ember install, you should have a fastboot directory in
either your app or your addon. Files in this fastboot directory will
be included when running ember fastboot:build or ember fastboot:server, but no other time. Do not rely on code in
fastboot to run in the browser build. Files in fastboot will NOT be
included in the normal browser build.
For example, you may have an addon that runs in both node and the browser. Here's the browser code:
// addon/get-json.js
import Ember from 'ember';
export default function getJSON(url) {
return Ember.$.getJSON(url);
}
Here's how someone would require that module:
// app/routes/application.js
import Ember from 'ember';
import getJSON from 'my-cool-ajax-addon/get-json';
export default Ember.Route.extend({
model() {
return getJSON('https://fivetanley.cloudant.com/docs');
}
});
This code however, won't run in node due to jQuery's getJSON method
requiring XMLHttpRequest, which is not available in node. We can
write a addon/fastboot/get-json.js file that requires a node library
to do the same thing:
// addon/fastboot/get-json.js
import {require} from 'ember-cli-fastboot-addon';
export default function(url) {
// https://github.com/mzabriskie/axios
const axios = require('axios');
return axios({
url: url,
responseType: 'json'
});
}
With this method, you don't have to change your app code! Your import
statements remain the same.
You need to import require from ember-cli-fastboot-addon like this:
import {require} from 'ember-cli-fastboot-addon';
Then you can use require like you would in Node/Browserify/Webpack.
You should definitely take a look at ember-browserify.
At build time, this addon checks for the presence of the
EMBER_CLI_FASTBOOT environment variable. This will be set by
ember-cli-fastboot.
Next, it looks at the addon (if this is an addon) and app directories. If there is a fastboot folder, it overwrites the files that would normally run in the browser with files from the fastboot folder.
If you had addon/index.js and addon/fastboot/index.js, the contents
of addon/fastboot/index.js would appear as the index file instead in
fastboot builds only. Otherwise, the normal addon/index.js file would
be used instead.
git clone this repositorynpm installbower installember servernpm test (Runs ember try:testall to test your addon against multiple Ember versions)ember testember test --serverember buildFor more information on using ember-cli, visit http://www.ember-cli.com/.
FAQs
The default blueprint for ember-cli addons.
The npm package ember-cli-fastboot-addon receives a total of 1 weekly downloads. As such, ember-cli-fastboot-addon popularity was classified as not popular.
We found that ember-cli-fastboot-addon demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Security News
CVE disclosures hit a record 48,185 in 2025, driven largely by vulnerabilities in third-party WordPress plugins.

Security News
Socket CEO Feross Aboukhadijeh joins Insecure Agents to discuss CVE remediation and why supply chain attacks require a different security approach.

Security News
Tailwind Labs laid off 75% of its engineering team after revenue dropped 80%, as LLMs redirect traffic away from documentation where developers discover paid products.