This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// This fails in firefox, chrome, and maybe others. | |
// Add a semicolon after foo() and to eliminate the error. | |
function foo() { /* code goes here */ } | |
foo() // no semi-colon here | |
(function() { /* anonymouse function */ })() // bork! | |
//You can also write the closure like this instead of putting a semicolon after foo: | |
//!function() { /* anonymouse function */ }() // bork! |