Invisible performance. How fast is your JavaScript code?
summary
Covers practical JavaScript performance tips: use 'use strict' and a linter (Standard) to catch bad patterns, prefer high-level constructs like Object maps and Object.assign instead of long if/else chains, and use LRU caches to avoid repeated expensive work (e.g., regex or distance calculations). Recommends factory/composition instead of new/constructors to reduce prototype/memory issues, avoid heavy regexes when simple string checks suffice, and prefer native methods and block-scoped let/const over var for more predictable performance.
AI-written summary · about
chapters (11)
- 0:00Introduction
- 7:19Use 'use strict'
- 15:25Avoid 'else' and 'switch' with objects
- 18:12Cache frequent results
- 21:25Use native JS methods
- 24:54Declare with 'let' and 'const'
- 26:42RegEx: when and how
- 31:11Avoid unnecessary 'bind'
- 33:41Constructor alternatives
- 43:17Simplicity for performance
- 44:21Q&A
related talks
29mExtreme JavaScript Performance
31mJavaScript Compilation Techniques or "Wasn't JavaScript supposed to be slow?"
46m10 secrets to improve Javascript Performance
58mImproving the Quality of JavaScript Code
34mUnderstanding JavaScript Performance
51mJavaScript Gotchas
03mTalking about NodeJS
54mPatterns for Programming in JavaScript
