I'm trying to implement frontend JWT authentication in angular, but the $stateChangeStart event is not firing between states. I'm using a component based architecture written in es2015 and bundled together with Webpack.

When I switch between states, the $stateChangeStart listener, set up in the run block, does not fire.

app.js is the entry point into the app. I'm including other angular modules as components.

```js
import 'normalize.css';
import {appDirective} from './app.directive';

// Angular Dependencies
import angular from 'angular';
import uiRouter from 'angular-ui-router';
import ngAnimate from 'angular-animate';

// JWT Dependencies
import angularJwt from 'angular-jwt';
import angularStorage from 'angular-storage';

// Import shared services
import {services} from './services/services';

// Import components
import {signup} from './components/signup/signup';
import {login} from './components/login/login';
import {dashboard} from './components/dashboard/dashboard';

angular.module('app', [
  uiRouter,
  ngAnimate,
  angularJwt,
  angularStorage,

services.name,

signup.name,
login.name,
dashboard.name

])
.directive('app', appDirective)

// config $httpInterceptors to attach JWT tokens

.run(function($rootScope, $state, Auth) {
  $rootScope.$on('$stateChangeSuccess', function(e, to){
    // Check for authentication, but function does not execute
  });
});

```

Here's an example of a components' entry point file. I set up the state for each component in these files.

```
import {dashboardDirective} from './dashboard.directive';
import angular from 'angular';
import uiRouter from 'angular-ui-router';

export const dashboard = angular.module('dashboard', [uiRouter])
  .config(($stateProvider) => {
    $stateProvider.state('dashboard', {
      url: '/dashboard',
      template: '<dashboard></dashboard>',
      authenticate: true
    });
  })
  .directive('dashboard', dashboardDirective);

```

Using the .run block on the main app module to set up the listener for state changes works fine with other app architectures, but I cannot seem to understand why it is not working here.