This step is really only needed to change the default https_only setting. In my case, it contains the host I wanted to deploy it to and any localhost port:ġ // app/routes/bands/band/songs.js 2 import Ember from ' ember ' Ĩ if ( this.get( ' fastboot.isFastBoot ')) You also have to add the hosts that will serve your Ember app in FastBoot mode to a list called hostWhitelist in your app's configuration. The fix here was to disable Mirage in development (and, in my case, production, too) and to make the requests against an actual API. I used it in development, too, and it turned out that since it turns itself off when your app is running in FastBoot mode, the requests hitherto handled by Mirage now went out and were thus unhandled. Mirage is a great tool for mocking server responses and even prototyping your Ember app. My first obstacle turned out to be Mirage. I then disabled JavaScript in my browser and then directed my browser to Disabling JavaScript in Chrome is most easily done by expanding the context menu of Developer Tools and then clicking on Settings:
FASTBOOT SOURCE CODE CODE
It's important to note that you should refresh your browser tab each time you make changes to your code as FastBoot doesn't (yet) auto-refresh the way ember server does. Installing the add-onįastBoot is a regular Ember add-on, so installing it is piece of cake:įrom the project's directory and had the node server serving my application at port 3000. Below, I'm going to tell you about the challenges I encountered and how I overcame them in the hope that my journey will prove valuable when you do the same for your app. I recently went through the process of enabling the demo version of the Rock and Roll application to run in Fastboot. In other words, the "time to first tweet" of your app is greatly reduced, which is a big win where and when people have slow or unstable network connections.Īnother advantage is that search engine crawlers will have an easier job indexing your site, which brings SEO benefits.įurthermore, your site will be readable with Javascript disabled which is convenient for screen readers. This will make users of your application see the content of your page before any of the javascript is downloaded. 11 November 2016 What is FastBoot and why should you use it?įastBoot is the awesome add-on that adds server-side rendering to your Ember app.