Reputation: 151
I am new to ember. If u find my question silly please dont mind.
I have a route '/lobby' which shows a different options.
when user chooses one particular option i want to create route /lobby/option_choosen(this will be the value which user chosen).
How to create route in ember in this scenario.
Upvotes: 0
Views: 173
Reputation: 12872
Please read ember guide dynamic segment part for defining routes. and for model preparing you can read dynamic model .
In router.js,
Router.map(function() {
this.route('lobbies');
this.route('lobby', { path: '/lobby/:lobby_id' });
});
Upvotes: 1