I have the router.js file of my project set up as follows:
Router.map(function() {
this.route('login');
this.route('projects', {path: '/'});
});
Whenever I visit the /login
page, no content is displayed. Also, the following error appears in the console:
Error: There is no route named index
However, whenever I remove {path: '/'}
from route, the login page works without issue.
Why is this happening? I've noticed that in other Ember projects like Ghost are able to achieve this just fine without any conflicts with a non-existent index route.
Note: I am using an ember-simple-auth mixin to redirect the visitor from /
to /login
.
Aucun commentaire:
Enregistrer un commentaire