conditionals, looping, comparison operators, object, arrays, etc
- attribute selector (dot or array syntax)
- in operator
- type conversions
true == '1'
- ===
true === '1'
- NaN, undefined, null
- functions are the only scope barrier
- pulling scope into a
- show example of pulling state in
- encapsulation
var counter = function() {
var count = 0;
var inc = function() {
count += 1;
return count;
}
var dec = function() {
count -= 1;
return count;
}
return [inc, dec];
}
difference between var myFunc = function() {}
and function myFunc() {}
and lifting
- Functions are values
- Functions can have their context or "this" changed
- currying with
bind
- late binding of calls, to inheritance chain
- Object.getPrototypeOf()
- Constructor.prototype
Object.create(prototype)
Parent.call(this, arguments)
- npm or yarn
- webpack - precompiler(babel, jsx, erb, etc)
- webpack - commonjs, amd modules
- brower plugins
- underscore
- immutable
- react/redux/router
the language - http://eloquentjavascript.net the toolchain - npm, es6, webpack(commonjs, amd) frameworks - react, underscore, immutable