Comments on: The FOUC Problem https://webkit.org/blog/66/the-fouc-problem/ Open Source Web Browser Engine Sun, 25 Feb 2007 07:47:06 +0000 hourly 1 https://wordpress.org/?v=6.5.2 By: JonathanAquino https://webkit.org/blog/66/the-fouc-problem/comment-page-1/#comment-18377 Sun, 25 Feb 2007 07:47:06 +0000 http://webkit.org/blog/?p=66#comment-18377 I think I’ve found a simple workaround: first CSS file just hides the body; last CSS file just shows the body. More info at http://jonaquino.blogspot.com/2007/02/workaround-for-safari-fouc-bug.html

]]>
By: cian https://webkit.org/blog/66/the-fouc-problem/comment-page-1/#comment-12485 Tue, 31 Oct 2006 21:39:30 +0000 http://webkit.org/blog/?p=66#comment-12485 The Nokia E61 (which runs WebKit) does a lot of FOUCing actually, I wonder if this will be fixed with a nokia upgrade…

]]>
By: hyatt https://webkit.org/blog/66/the-fouc-problem/comment-page-1/#comment-12094 Mon, 18 Sep 2006 06:14:34 +0000 http://webkit.org/blog/?p=66#comment-12094 humorless, not sure why you can’t upload files. Do you have any Safari extensions installed? You might try uninstalling them if so.

]]>
By: xenon https://webkit.org/blog/66/the-fouc-problem/comment-page-1/#comment-12083 Sun, 10 Sep 2006 18:49:50 +0000 http://webkit.org/blog/?p=66#comment-12083 @boult, that is a recent regression that has now been fixed in the latest nightlies.

]]>
By: heckenpenner_rot https://webkit.org/blog/66/the-fouc-problem/comment-page-1/#comment-12076 Tue, 05 Sep 2006 21:06:30 +0000 http://webkit.org/blog/?p=66#comment-12076 “In WebKit (and Gecko) all pages parse and execute script on the main thread (the UI of the browser renders and responds to events on this thread as well). Thus blocking the thread that JS is running on blocks everything except network loading.”

Oh right, I wasn’t really aware of that; I mean, of the fact, that everything just runs in a single thread, namely the UI thread.

In this case, I am curious on your opinion whether this model is still viable for the long run? In particular, if we expect even more scripting stuff incorporated into future web pages. People are already doing quite complicated computations on the client side. Stuff like parsing JSON strings, calculating spreadsheets, etc is already
there and takes some time. And we can certainly expect a further shift of computations to the client side, I’d guess. I already see my rainbow spinning … 🙂

Are there any long term plans to change that model in WebKit? If so, what’s the way to go? Native “page threads”? A rewritten JS engine with explicit control state? Or both?

]]>
By: jburke https://webkit.org/blog/66/the-fouc-problem/comment-page-1/#comment-12074 Tue, 05 Sep 2006 06:36:59 +0000 http://webkit.org/blog/?p=66#comment-12074 Does the FOUC problem show up if we check for document.readyState to be loaded/completed before accessing the style properties in JavaScript? This check is used as part of a window.onload alternative that does not need to wait for things like images and iframes to load. But would it cause FOUC? For more info, see Dean Edward’s post: http://dean.edwards.name/weblog/2006/06/again/

]]>
By: boult https://webkit.org/blog/66/the-fouc-problem/comment-page-1/#comment-12073 Mon, 04 Sep 2006 05:56:41 +0000 http://webkit.org/blog/?p=66#comment-12073 Hyatt,
this is a off topic… just wanting to let you know that this nightly webkit app spawn a new page when a link is set to open new page but it load in same window at the same time spawn a new blank page. hmm..

is it a bug or feature… are you guys aware of this? (I am not programmer but I am just trying this webkit and it seems to run better than the stable Safari that came out in latest 10.4.x release… which I am glad it was able to load all animations live.)

]]>
By: Chris https://webkit.org/blog/66/the-fouc-problem/comment-page-1/#comment-12072 Mon, 04 Sep 2006 01:10:58 +0000 http://webkit.org/blog/?p=66#comment-12072 ‘If we lived in a world where every page had its own thread that was also independent of the UI thread, you could imagine that it might be ok to just block a “page thread”.’

Got it; this is not BeOS; gotta remember that. 🙂 Makes sense.

]]>
By: gazhay https://webkit.org/blog/66/the-fouc-problem/comment-page-1/#comment-12069 Sun, 03 Sep 2006 14:06:23 +0000 http://webkit.org/blog/?p=66#comment-12069 @macnold.

A developer can easily display a progress bar of his own, if he so wishes, and I always try to have some kind of progress indicator on tasks that are going to take a while.

I agree this is not a catch-all solution, but this problem in general is down to lazy web developers, there is so much you can do to stop this problem, but people just seem to code for ‘fairly good’ results in IE nowadays.

]]>
By: hyatt https://webkit.org/blog/66/the-fouc-problem/comment-page-1/#comment-12065 Sun, 03 Sep 2006 04:30:45 +0000 http://webkit.org/blog/?p=66#comment-12065 “Surely the JS engine must be able to block, because there are cases where it must do so or waste CPU time.”

There’s a difference between blocking by stalling an entire thread and saving off state, yielding and resuming later. If we lived in a world where every page had its own thread that was also independent of the UI thread, you could imagine that it might be ok to just block a “page thread”. We don’t though. (The reality is that pages are typically network-bound enough that there isn’t much benefit to dramatically complicating the code just for a bit of parallelization that would only be useful in very limited circumstances.)

In WebKit (and Gecko) all pages parse and execute script on the main thread (the UI of the browser renders and responds to events on this thread as well). Thus blocking the thread that JS is running on blocks everything except network loading.

“Is there just a single thread that does both the parsing and also the execution of the JS scripts tags? And in this thread, you then manually alternate between the parsing and the JS engine?”

Correct, one thread. There isn’t really “alternation” though. You just run scripts as they are encountered (and loaded) in the page. Scripts block parsing. Even if you did suspend JS, you couldn’t keep parsing that particular page. Therefore there is no benefit to separating into multiple threads based on script execution vs. page parsing.

]]>