Setup

Ember FW GC has one of the more complicated setups of any of the packages, but all of this has already been done for you because Ember FW GC has been set up for you by the Generator FW, so all of the apps should have all these steps completed.

Base Setup

Of course, to begin, you need to add the yarn dependency for @bennerinformatics/ember-fw-gc to the client/package.json file, as documented here. Then, as with many of our packages, you must import the styling for the addon in your app.scss:

@import "ember-fw-gc/ember-fw-gc";

You also need to make sure that the gc app is set as a dependency in your fw.json, like so:

"dependencies": {
    "apps": {
      "gc": "^1.4.14"
    }
  }

After these steps are completed is where it gets complicated, because there are a variety of files that need to be edited.

Router.js

Because there are several pages that are added by Ember FW GC, you must make sure that these routes are imported. This can be done by importing the authRoute function from ember-fw-gc router, like so:

import authRouter from '@bennerinformatics/ember-fw-gc/router';

EmberRouter.map(function () {
    //... all app specific routes

    // Don't remove this as it is needed to setup important routes
    authRouter(this);
});

This will generate the routes: login, forgot, reset, and profile.

Importing Mixins

There are several mixins which should be added in order to properly have everything in the app to function. Rather than listing exactly how to import each of these mixins, I will just link to the API Docs for each of them, which explains where and how each of these should be done: ApplicationControllerMixin, IndexRouteMixin, and DepartmentTransitionMixin.

Relogin Modal

Finally, you should make sure to have the code to open the Re-Login Modal, as described in its API Docs.

Again all of this is done for you already in each app, but it is just helpful to list all the steps you need here in order to properly set up the app with Ember FW GC.