Tuesday, 22 October 2013

Improve Javascript Performance

We need to follow some step and get bit more faster make our website with any platform.

  1. First all remove duplicate instance inside of application i.e declare var i = 0 then doesn't repeat again.
  2. Write return false when function will closed if not need to go ahead within function 
  3. Declare only once of selector for any control in JavaScript i.e var txt = document.getElementById('txtid')
After then need to use txt variable in whole application.

No comments:

Post a Comment