Wednesday, September 11, 2013

JavaScript API to control loading progress indicator in browser adress bar

Instead of adding a JavaScript library to indicate the loading progress of a page I propose creating a JavaScript browser API that allows the programmer to set (or get) the position of the loading bar in percent. This is useful because many sites or single-page applications asynchronously load content.

As an example it could live as an object in the window.navigator.progress namespace and have the following functions:

set the progress bar to zero

set( percent )
set the progress bar to the given percentage value

set the progress bar to the full position and possibly hide it

returns the current loading progress in percent

Having said that, I noticed, that the browsers I use (firefox and chromium) don't even have the loading progress indicator anymore. I can only speculate, that this is because the vendors noticed, that the indicator wasn't helping much anymore due to the increased usage of javascript to control content in the DOM. I think that bringing back the indicator and handing control over it to the developers would be a nice touch in terms of usability.


Afzal khan said...

Great things you’ve always shared with us. Just keep writing this kind of posts.The time which was wasted in traveling for tuition now it can be used for studies.Thanks UC mini for android

Adiba Alam said...

With rich parts of work in media of HTML5 and CSS3, there is no requirement for including program modules, for example, Flash Player to the web programs, and sites.javascript

for IT the said...

Hi, Great.. Tutorial is just awesome..It is really helpful for a newbie like me.. I am a regular follower of your blog. Really very informative post you shared here. Kindly keep blogging. If anyone wants to become a Front end developer learn from Javascript Training in Chennai . or learn thru JavaScript Online Training India. Nowadays JavaScript has tons of job opportunities on various vertical industry.

Dick Snyder said...

What an amazing article, I learned a lot of new from it. Its very cool that in our modern world people still share useful information with each others. I am such person too, and wanna share with everyone javascript snake tutorial that helped me to build an excellent snake!)