title: How to get all registered routers in ember (version 2.4.6) by es6
body: <p>I need a list of all registered routers in ember app.
  After searching on the Internet, I've found the link below:</p>
  
  <p><a href="https://stackoverflow.com/questions/15756458/can-we-view-all-the-routes-in-emberjs-aka-something-similar-to-what-rake-routes">can we view all the routes in emberjs aka something similar to what rake routes does in rails</a></p>
  
  <p><a href="https://stackoverflow.com/questions/28274005/getting-a-list-of-routes-in-ember-js">Getting a list of routes in Ember.js</a></p>
  
  <p>But it does not work for me.</p>
  
  <p>this is App.js</p>
  
  <pre><code>import Ember from 'ember';
  import Resolver from './resolver';
  import loadInitializers from 'ember-load-initializers';
  import config from './config/environment';
  let App;
  Ember.MODEL_FACTORY_INJECTIONS = true;
  App = Ember.Application.extend({
    modulePrefix: config.modulePrefix,
    podModulePrefix: config.podModulePrefix,
      Resolver,
      ready: function () {  
      }
  });
  loadInitializers(App, config.modulePrefix);    
  export default App;
  </code></pre>
  
  <p>this is router.js</p>
  
  <pre><code>import Ember from 'ember';
  import config from './config/environment';
  
  const Router = Ember.Router.extend({
      location: config.locationType
  });
  
  Router.map(function() {    
      this.route('about');
      this.route('login');
  });
  
  export default Router;
  </code></pre>
  
  <hr>
  
  <p>and this is Application Conroller for get all routers</p>
  
  <pre><code>import Ember from 'ember';
  import App from 'ember-app/app';
  
  export default Ember.Controller.extend({
      allRouter: [],
  
      allRouterCalc: Ember.computed('allRouter', function() {        
          let allRouter = this.get('allRouter');
          if(allRouter.length === 0)
          {
              allRouter = App.Router.router.recognizer.names;
          }        
          return allRouter;
      })
  });
  </code></pre>
  
  <hr>
  
  <p>but when I called "allRouterCalc" variable, this error This bug occurs:
  "Cannot read property 'router' of undefined" .</p>
  
  <p>This problem arises because the "Router" in "App.Router" is "undefined".</p>
  
  <p>why "Router"  is "undefined" ?</p>