$scope

scope for resolving event and method names

object $scope;

Example

some.$scope = {
   action:function(){ alert("works"); }
};
some.attachEvent("onItemClick", "action");

Details

When event name or click handler defined as string name, component will check is the handler with such name exists in the $scope object first, and only after that will try to locate the global handler with the same name.

Back to top
Join Our Forum
We've retired comments here. Visit our forum for faster technical support, connect with other developers, and share your feedback there.