Accessing dynamic segments in a nested route


#1

I’m trying to access params in a route nested in a route resource. Are the dynamic segments supposed to be accessible in the routes under the resource? for example see the linked gist:


#2

actually, found this related post Nested resources and dynamic segments so nevermind


#3

For future references, this might be useful when you want to access all the params outside of the route:

  getActiveRouteParameters: function () {
        var parameters = {};
        try {
            App.Router.router.currentHandlerInfos.forEach(function (handler) {
                Ember.merge(parameters, handler.params);
            });
            return parameters;
        } catch (error) {
            return {};
        }
    }