Skip to content

Instantly share code, notes, and snippets.

@jondlm jondlm/functions.js
Last active Aug 29, 2015

Embed
What would you like to do?
Functions
// -------------------------------------
// Example 1 (function expression)
//
test(); // Won't work
var test = function () {
alert('Yolo');
};
// -------------------------------------
// Example 2 (function declaraction)
//
test2(); // Does work!
function test2 () {
alert('Yolo');
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.