I am trying to restructure the closely related parts of the ember.js application, especially the views and templates for controllers.
All the examples that I saw connect views directly to controllers in the definition of the view class or pass the (global) path to the view in the template itself.
The TargetActionSupport mixer (DelegateSupport in sproutcore, I think) seems like a good candidate, but still requires the target (controller) and action to be set in the template itself.
Ideally, I would like to instantiate my views in my controller (somehow), set goals and actions, but also set the current variables in my templates (e.g. static classes, id), but I'm not sure how to do that this, or this is the right approach.
source share