title: How to use RouteConfig in Angular2 with plain JavaScript?
body: <p>I am building an app using Angular 2 with plain JavaScript and I can't find any example of how to use RouteConfig for JavaScript (not ts).</p>
  
  <p>Can anyone give me an example of how to use.
  I tried like this but it's not working:</p>
  
  <pre><code>(function(app) {
      app.MainComponent =
          ng.core.Component({
                  selector: 'app',
                  templateUrl: 'app/components/main/main.view.html'
              })
              .Class({
                  constructor: function() {}
              })
              .RouteConfig([
                  {path: '/', redirectTo: '/job'},
                  {path: '/job', component: JobViewComponent }
              ])
      ;
  
  })(window.app || (window.app = {}));
  </code></pre>
  
  <p>And I have other file that is JobView</p>
  
  <pre><code>(function(app) {
      app.JobViewComponent =
          ng.core.Component({
                  selector: 'job-view',
                  templateUrl: 'app/components/job_view/job_view.view.html'
              })
              .Class({
                  constructor: function() {}
              });
  })(window.app || (window.app = {}));
  </code></pre>
  
  <p>Thanks.</p>