<html><head><base href="x-msg://125/"></head><body style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space; ">This is false. WebKit will block the parser when it encounters an external script if there are pending stylesheet loads. However we have a speculative preloader that will continue to parse and load resources beyond that script (but the real parser will be blocked).<div><br></div><div>dave</div><div><br><div><div><div>On Dec 9, 2009, at 3:42 PM, tali garsiel wrote:</div><br class="Apple-interchange-newline"><blockquote type="cite"><span class="Apple-style-span" style="border-collapse: separate; font-family: Helvetica; font-size: medium; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; orphans: 2; text-indent: 0px; text-transform: none; white-space: normal; widows: 2; word-spacing: 0px; -webkit-border-horizontal-spacing: 0px; -webkit-border-vertical-spacing: 0px; -webkit-text-decorations-in-effect: none; -webkit-text-size-adjust: auto; -webkit-text-stroke-width: 0px; "><div class="hmmessage" style="font-size: 10pt; font-family: Verdana; ">Well, not completely.<div>Regarding the first question- Webkit guys told me (on their IRC channel) that the don't block the parser and only block scripts that request visual information, so I'm still confused.<br><br>> Date: Wed, 9 Dec 2009 17:01:30 +0000<br>> From:<span class="Apple-converted-space"> </span><a href="mailto:ian@hixie.ch">ian@hixie.ch</a><br>> To:<span class="Apple-converted-space"> </span><a href="mailto:t_garsiel@hotmail.com">t_garsiel@hotmail.com</a>;<span class="Apple-converted-space"> </span><a href="mailto:bzbarsky@MIT.EDU">bzbarsky@MIT.EDU</a><br>> CC:<span class="Apple-converted-space"> </span><a href="mailto:whatwg@whatwg.org">whatwg@whatwg.org</a><br>> Subject: Re: [whatwg] style sheet blocking scripts<br>><span class="Apple-converted-space"> </span><br>> On Wed, 28 Oct 2009, tali garsiel wrote:<br>> ><span class="Apple-converted-space"> </span><br>> > This is a quote from Section 4.2 of the spec:<br>> ><span class="Apple-converted-space"> </span><br>> > "A style sheet in the context of the Document of an HTML parser or XML<span class="Apple-converted-space"> </span><br>> > parser is said to be a style sheet blocking scripts if the element was<span class="Apple-converted-space"> </span><br>> > created by that Document's parser, and the element is either a style<span class="Apple-converted-space"> </span><br>> > element or a link element that was an external resource link that<span class="Apple-converted-space"> </span><br>> > contributes to the styling processing model when the element was c reated<span class="Apple-converted-space"> </span><br>> > by the parser, and the element's style sheet was enabled when the<span class="Apple-converted-space"> </span><br>> > element was created by the parser, and the element's style sheet ready<span class="Apple-converted-space"> </span><br>> > flag is not yet set, and, the last time the event loop reached step 1,<span class="Apple-converted-space"> </span><br>> > the element was in that Document"<br>> ><span class="Apple-converted-space"> </span><br>> > And the section about parsing - the "<script>" tag says that before<span class="Apple-converted-space"> </span><br>> > executing a script the parser must:<br>> ><span class="Apple-converted-space"> </span><br>> > 3. Spin the event loop until there is no style sheet blocking scripts<span class="Apple-converted-space"> </span><br>> > and the script's "ready to be parser-executed" flag is set.<br>> ><span class="Apple-converted-space"> </span><br>> > I have two questions:<br>> ><span class="Apple-converted-space"> </span><br>> > 1. As far as I know, Firefox and Webkit have a "stall on demand"<span class="Apple-converted-space"> </span><br>> > behavior, where a stylesheet blocks a script only if the script asks<span class="Apple-converted-space"> </span><br>> > from style information. According to the spec the style sheet always<span class="Apple-converted-space"> </span><br>> > blocks a script, am I right?<br>> ><span class="Apple-converted-space"> </span><br>> > 2. Can you clarify the condition - "the element's style sheet was<span class="Apple-converted-space"> </span><br>> > enabled when the element was created by the parser, and the element's<span class="Apple-converted-space"> </span><br>> > style sheet ready flag is not yet set, and, the last time the event loop<span class="Apple-converted-space"> </span><br>> > reached step 1, the element was in that Document"<br>> ><span class="Apple-converted-space"> </span><br>> > Does it mean the style sheet blocks scripts only if it's currently being<span class="Apple-converted-space"> </span><br>> > parsed?<br>><span class="Apple-converted-space"> </span><br>> On Wed, 28 Oct 2009, Boris Zbarsky wrote:<br>> > On 10/28/09 2:59 AM, tali garsiel wrote:<br>> > > 1. As far as I know, Firefox and Webkit have a "stall on demand"<span class="Apple-converted-space"> </span><br>> > > behavior, where a stylesheet blocks a script only if the script asks<span class="Apple-converted-space"> </span><br>> > > from style information.<br>> ><span class="Apple-converted-space"> </span><br>> > You know wrong, sorry. Firefox has the behavior the spec describes;<span class="Apple-converted-space"> </span><br>> > webkit blocks the parser completely on stylesheets (the behavior Firefox<span class="Apple-converted-space"> </span><br>> > used to have). Last I chec ked, at least.<br>> ><span class="Apple-converted-space"> </span><br>> > > 2. Can you clarify the condition - "the element's style sheet was<span class="Apple-converted-space"> </span><br>> > > enabled when the element was created by the parser, and the element's<span class="Apple-converted-space"> </span><br>> > > style sheet ready flag is not yet set, and, the last time the event<span class="Apple-converted-space"> </span><br>> > > loop reached step 1, the element was in that Document"<br>> ><span class="Apple-converted-space"> </span><br>> > The parts of that condition basically mean:<br>> ><span class="Apple-converted-space"> </span><br>> > 1) When the element was created by the parser, it was in the then-enabled<br>> > stylesheet set (i.e. not an alternate stylesheet).<br>> > 2) The stylesheet, or one of its @import descendants, is still loading.<br>> > 3) The stylesheet linking element is still in the document (so the stylesheet<br>> > still applies).<br>><span class="Apple-converted-space"> </span><br>> Thanks Boris.<br>><span class="Apple-converted-space"> </span><br>> Tali, does this answer your question to your satisfaction?<br>><span class="Apple-converted-space"> </span><br>> --<span class="Apple-converted-space"> </span><br>> Ian Hickson U+1047E )\._.,--....,'``. fL<br>><span class="Apple-converted-space"> </span><a href="http://ln.hixie.ch/">http://ln.hixie.ch/</a><span class="Apple-converted-space"> </span>U+263A /, _.. \ _\ ;`._ ,.<br>> Things that are impossible just take longer. `._.-(,_..'--(,_..'`-.;.'<br></div><br><hr>Windows Live Hotmail:<span class="Apple-converted-space"> </span><a href="http://www.microsoft.com/middleeast/windows/windowslive/see-it-in-action/social-network-basics.aspx?ocid=PID23461::T:WLMTAGL:ON:WL:en-xm:SI_SB_4:092009" target="_new">Your friends can get your Facebook updates, right from HotmailŪ.</a></div></span></blockquote></div><br></div></div></body></html>