Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Majority time is idle when loading a webpage

We are developing a web application.

Now the page loading is very slow (>20s). I am using Chrome DevTools Timeline to debug. What I find is that majority of the time is 'Idle'. What is the problem? What is the browser doing when it is 'idle'? Is it because the slow network access speed? Thanks.

enter image description hereenter image description here

like image 500
Joy Avatar asked Apr 03 '14 08:04

Joy


2 Answers

This could mean your page actually finished loading within ~2.5s. But you may have scripts running that tell your browser to do something every once in a while, for example refresh an ad creative every 5 seconds.

It's hard to know what's actually happening without looking at your site. It'll help if you provide a link.

like image 57
Byron Singh Avatar answered Oct 20 '22 01:10

Byron Singh


Ok, I had the same issue , think I now know what is the problem: the reason your page is idle for a long time is, most probably it is asking for a resource that is not reachable! in my case, the idle periode ( 30 seconds ) was because somewhere in my styles.css file I have this line of code : @import url(//netdna.bootstrapcdn.com/font-awesome/4.0.3/css/font-awesome.css); as it could not resolve the url, it takes a very long time for chrome to get over it.

in your chrome DevTools, under Network tab, look which of the resources are not resovled.

like image 21
makarbasi Avatar answered Oct 20 '22 00:10

makarbasi