7 Surprising Ways to Speed Up Your Site!!!

These are my optimization tips for JavaScript.

  1. Do less IO. (Fewer, smaller HTTP reqs. But mostly just fewer.)
  2. Do slow operations in ways that don’t block user interaction. (Aka “async” or “cheating”.)
  3. Write smaller programs. Cut unnecessary features. Most software latency and bugs come from code, so use less of that.
  4. Profile before you optimize, or go blind from pointless bit twiddling masturbation.
  5. Profile your actual app with actual data. Microbenchmarks are often inapplicable.
  6. Write code that you can read and understand.
  7. Don’t believe anything you read on the internet about speeding up your site until you have verified it for yourself, in the context of your app.