Skip to content

Instantly share code, notes, and snippets.

@toolmantim
Created August 28, 2009 01:24
Show Gist options
  • Select an option

  • Save toolmantim/176716 to your computer and use it in GitHub Desktop.

Select an option

Save toolmantim/176716 to your computer and use it in GitHub Desktop.
// Adds controller methods to elements
$$ = function(elem, methods) {
if (methods) $(elem).data("controller", methods);
return $(elem).data("controller");
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment