Skip to content

Instantly share code, notes, and snippets.

@yamamoto-febc
Created June 12, 2012 13:11
Show Gist options
  • Save yamamoto-febc/2917414 to your computer and use it in GitHub Desktop.
Save yamamoto-febc/2917414 to your computer and use it in GitHub Desktop.
javascript docment1
$.Controller("MyWidget",
{
defaults : {
message : "Remove Me"
}
},
{
init : function(rawEl, rawOptions){
this.element.append(
"<div>"+this.options.message+"</div>"
);
},
"div click" : function(div, ev){
div.remove();
}
})
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment