NPM Useful commands List globally installed NPM packages and versions: npm list -g --depth=0 Get directory where global modules are located: npm root -g Update rules
'this' in JavaScript The value of this differs depending on how a function is invoked. There're main rules and some exceptions. Rules 'new' binding function Foo() { this.bar = 'bar'; }