Skip to content

Instantly share code, notes, and snippets.

@hojberg
Created December 8, 2009 15:08
Show Gist options
  • Save hojberg/251709 to your computer and use it in GitHub Desktop.
Save hojberg/251709 to your computer and use it in GitHub Desktop.
var app = {
before: function () { console.log("i am going to be runned before all other functions") },
func1: function () {
console.log("func1");
},
func2: function () {
console.log("func2");
}
};
app.funct1();
// i am going to be runned before all other functions
// func1
app.funct2();
// i am going to be runned before all other functions
// func2
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment