Skip to content

A Ubiquitous Mind

Welcome to my mind, dreams and thoughts

  • Portfolio
    • Dribbbles
    • 2011
  • Design
    • Fonts
    • CSS
    • Posters
    • Inspiration
  • Codes
    • Troubleshooting
    • Tutorials
    • WordPress
  • Cool Stuff
    • tricks
  • Useful links
    • Tools
    • People to Follow
  • About

Tag: DOM

JS Performance: 10 Commandments

04.11.2015 Shavin FonsekaLeave a comment

  1. Don’t touch the DOM
  2. Cache DOM reference in local vars
  3. Use selectors API
  4. Cahce the length when looping collections
  5. Update the DOM offline
  6. Batch style changes
  7. Don’t ask for layout info excessively
  8. Minimize reflow areas
  9. Use event delegation
  10. Don’t touch the DOM
Posted in UncategorizedTagged 10, cache, Code, commandments, DOM, javascript, js, local, performance, scripts, styles, vars
Blog at WordPress.com.
Privacy & Cookies: This site uses cookies. By continuing to use this website, you agree to their use.
To find out more, including how to control cookies, see here: Cookie Policy
  • Follow Following
    • A Ubiquitous Mind
    • Join 41 other followers
    • Already have a WordPress.com account? Log in now.
    • A Ubiquitous Mind
    • Customize
    • Follow Following
    • Sign up
    • Log in
    • Report this content
    • View site in Reader
    • Manage subscriptions
    • Collapse this bar