jQuery is a JavaScript framework that is widely used and very impressive, but there are some things we must consider in making the code-code because it affects the speed dialing / load jQuery. Sometimes we hope that by using the jQuery framework to make our blogs look more beautiful and professional but it makes the speed of loading the pages of our blog to be heavy. Indeed, many factors that affect the speed of loading pages our blog, one of whom is writing jQuery code that is not proper. A few moments ago Blogger Tune-Up ever discuss "Management Scripts jQuery" and "Understanding and Overcoming Conflict Scripts jQuery" and hope my friends understand it because bloggers are now more directed to the discussion of writing a script that is more specific.
Below are the things that need our attention in writing scripts jQuery
1. Use more specific selector
If we menulisakan jQuery code to search for a particular element, the more information provided the faster process of discovery of elements. Suggested uses ID to expedite search and avoid using the class element.
This technique is similar to the process of finding the home address, the complete address of the faster process of discovery. But if we just give a little information on the search will be performed on all elements of the DOM structure to be found and this slows the process of loading the script, look at an example:
Below are the things that need our attention in writing scripts jQuery
1. Use more specific selector
If we menulisakan jQuery code to search for a particular element, the more information provided the faster process of discovery of elements. Suggested uses ID to expedite search and avoid using the class element.
This technique is similar to the process of finding the home address, the complete address of the faster process of discovery. But if we just give a little information on the search will be performed on all elements of the DOM structure to be found and this slows the process of loading the script, look at an example:
Writing the code below will be faster than the code above:
2. Simplify Several selector (Multiple Selectors)
If we use the same functions with different elements, it is possible to combine multiple selector to speed it up and avoid the repetition of the same reading of the DOM or not needed.
If we use the same functions with different elements, it is possible to combine multiple selector to speed it up and avoid the repetition of the same reading of the DOM or not needed.
3. Use Multiple Properties (Properties) and Value (Values)
Several methods of jQuery is capable of accepting several properties and values rather than just a pair of properties and values. Wrote several properties at once will help accelerate the jQuery performance and reduce the number of objects that we write jQuery.
Several methods of jQuery is capable of accepting several properties and values rather than just a pair of properties and values. Wrote several properties at once will help accelerate the jQuery performance and reduce the number of objects that we write jQuery.
4th. Always Use $ (this)
If we use the selector through the DOM element in seeking to perform specific functions and elements have been previously tertuliskan then we can write these functions using $ (this).
Code below will cross the DOM twice just to take the same elements:
If we use the selector through the DOM element in seeking to perform specific functions and elements have been previously tertuliskan then we can write these functions using $ (this).
Code below will cross the DOM twice just to take the same elements:
Related Post :
info
,
tips-n-trick
0 komentar to "Accelerate jQuery Script"
Follow me please
Blog Archive
-
▼
2010
(177)
-
▼
July
(35)
- Earn money from blog / your website
- Simplified Concept Advertising Publisher Business
- Version of Article Writing Blog Darren Rowse
- tukar link doffolow gratis
- What is RSS and Feeds?
- PageRank
- such as whether a professional blogger?
- Accelerate jQuery Script
- Improve seo
- the right to improve the quality seo blog
- search result in esa-barker.blogspot.com
- Improve SEO Tips For Beginners
- Textpattern
- tips to improve google pagerank
- the results surrounding the blog
- To be accepted Your Blog Paid Review Broker
- Include your blog Internet Business Blog Blog Blog...
- Tips Generating more visitors to your blog
- Choosing the Best For Your Blog themes
- tips on choosing the theme of a special blog hunte...
- tips on choosing template adsense
- 5 Tips Free Style blog design
- Choosing The Right Template
- tips tricks so quickly indexed by google
- tricks to accelerate the increase pagerank
- SEO Tips for Beginners
- 5 Causes of Broken Links on the Blog
- 5 Tips For Beginner Bloggers
- tips replace templates for search engine friendly
- history blogspot or blogger
- Blogspot Basics: Know the parts - the element of b...
- how to advertise on our blog
- make a related post on the blog
- Free link exchange
- Make Money With Your Blog - Top Money Making Progr...
-
▼
July
(35)
coins 4 me :)
drop me
google analystic
Labels
Recent Visitor
blogroll
- >aditsubang
- >Belajar Trik Blog
- >Benfany's Project
- >Cek Info
- >Cool Tutorials Collections
- >Download area,Business,information and computer
- >Get & Share Information
- >health care
- >Igun Suka- Suka
- >indoblogger
- >Info Tech
- >Info Terbaru
- >Joomla SEO Optimation
- >Kreatif anak jalanan
- >Mikrotik
- >Multi Blogging
- >rizkyzone
- >saffa inspiration
- >Share Gadget
- >supermilan
- >suryainformation
- >Tatap Muka
- >TheFree-File
- >tyrips
- RakitWeb
- Resa web
Post a Comment
● Your feedback will I Reply
● Follow this blog you will I follow your blog
● if you Put my link, I put your link on my blog
● if exchanging links, plug on the front page blog, do not be in the post / article
● No Porn, Advertising , verbal abuse, Bad Words
● if you are to follow this blog, or put my links, request for confirmation, so follow your links or installation faster
● Happy Commenting