How can a Controller.extend({})
set a variable to be sent though Meteor.subscribe(); used in mongodb query. This can be done by creating whole new controller and putting a static variable in the subscribe function. ex Meteor.subscribe('collection', this.findOptions(),static variable);
The problem is that creates a lot of redundant code. Where as setting the variable in the Controller.extend({})
would not.
With meteor and iron router how can the same controller and publish function be used to publish different parts of a collection
123 views Asked by AudioBubble At
1
If you define a
waitOn
function that gathers the subscription(s) then you could do it there. I have some patterns like that in my app. For example a route used for a campaign landing page: