Jump to content

script and css load time


novicenate

Recommended Posts

there isn't really a definitive point.Its a general trend where, the more stuff there is to load, the longer the page will take to load. Different internet speeds will also affect load time, but be it on dial up or super duper mega fast it'll set fire to your underwear broadband speeds, the loading times will always increase the more stuff there is to load.:)

Link to comment
Share on other sites

well, I know that as you add more images the entire load time increases becuase images are 10-50 or even 100 KB in size each. but code is typically very small, even large pages of it, because it's just text. so I guess I was asking moreso since file size isn't much of a factor, does it take more time for a browser to "read" the large page of code and figure out how to display it, which then takes more time to load the page overall??

Link to comment
Share on other sites

well, I know that as you add more images the entire load time increases becuase images are 10-50 or even 100 KB in size each. but code is typically very small, even large pages of it, because it's just text. so I guess I was asking moreso since file size isn't much of a factor, does it take more time for a browser to "read" the large page of code and figure out how to display it, which then takes more time to load the page overall??

Link to comment
Share on other sites

Also, when you put your CSS and javascript in external files, the browser only has to download those files once. After the files have been downloaded, they are served from the browser's cache. If all of your pages use the same CSS, the visitor will only have to download your CSS file once on the first visit to your website. Then, as that visitor navigates through your site, his/her browser will load the CSS from cache and the experience will be much faster.So, if, like aspnetguy said, there are javascript libraries that are larger than 100KB, it may take some time to download it and the user may experience a delay, but this will only happen the first time the visitor comes to your site.

Link to comment
Share on other sites

Also, just so you know, every character on a page is 1 byte. If you have 1024 characters on a page, your file is 1KB. When you consider how much text shows up on a page like this, plus the HTML to render the text, pages get fairly large. Before I made this post Opera was reporting that the inline elements on this page (this thread) total over 130KB.

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...