Skip to content

Instantly share code, notes, and snippets.

@hakant
Last active April 3, 2016 14:36
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save hakant/8c94080e4c61ea04bfaf1a009dbcc25b to your computer and use it in GitHub Desktop.
Save hakant/8c94080e4c61ea04bfaf1a009dbcc25b to your computer and use it in GitHub Desktop.
Hackathon Planner - main.js
import 'bootstrap';
import {AuthService} from './infrastructure/auth-service';
import {inject} from 'aurelia-framework';
import 'fetch';
export function configure(aurelia) {
aurelia.use
.standardConfiguration()
.developmentLogging()
.plugin('aurelia-validation');
aurelia.start().then(() => {
var auth = aurelia.container.get(AuthService);
let root = auth.isAuthenticated() ? 'app' : 'login';
aurelia.setRoot(root);
});
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment