Speaker: Jesse Hallett
Return to this session's details
lexical scope -
for using '$.getJSON' in-line with 'for' loops, wise not to do 'for' loops, instead use: '[function instance name].forEach.' otherwise, could lose first return.
good coding syntax suggestion: variables should be lowercase, new constructors should be capitalized.
properties can be deleted. A function can take a function as a parameter (?)
Many higher order functions aren't implemented in ie. Can write yourself or import a library
Lexical scope: determined by where you declare. If you don't declare it is a global variable. To catch this use a syntax checker like jslint. Or some editors have tools to help.
Ecmascript has a new standard for a strict mode but it's not yet finalized or implemented.
If you declare a variable in a for loop it has same scope as the one declared outside it
Can borrow functions from other objects by using apply
Beware of index variables when using callbacks as the value may increment before the calLback happens. Eg Ajax is asynchronous.
Pattern of immediately calling function to avoidnpoliting global namespace. Self calling function
Functions are Objects. Can have attributes and methods.
Object.create easier way to use prototype
Qunit is a test framework that supports asynchronous testing
TDD Framework for node.js called Exspresso: http://tjholowaychuk.com/post/656851606/expresso-tdd-framework-for-nodejs
"test lifecycles" slide has typo: "same values OR -> ARE not equal"