W3C home > Mailing lists > Public > whatwg@whatwg.org > October 2009

[whatwg] style sheet blocking scripts

From: tali garsiel <t_garsiel@hotmail.com>
Date: Wed, 28 Oct 2009 06:59:14 +0000
Message-ID: <BAY117-W28009A67F3600230034B8783B80@phx.gbl>

Hi,

This is a quote from Section 4.2 of the spec:

"A style sheet in the context of the Document of an HTML parser or XML parser is said to be a style sheet blocking scripts if the element was created by that Document's parser, and the element is either a style element or a link element that was an external resource link that contributes to the styling processing model when the element was created by the parser, and the element's style sheet was enabled when the element was created by the parser, and the element's style sheet ready flag is not yet set, and, the last time the event loop reached step 1, the element was in that Document"


And the section about parsing - the "<script>" tag says that before executing a script the parser must:

3. Spin the event loop until there is no style sheet blocking scripts and the script's "ready to be parser-executed" flag is set.


I have two questions:

1. As far as I know, Firefox and Webkit have a "stall on demand" behavior, where a stylesheet blocks a script only if the script asks from style information. According to the spec the style sheet always blocks a script, am I right?

2. Can you clarify the condition - "the element's style sheet was enabled when the element was created by
the parser, and the element's style sheet ready flag is not yet set,
and, the last time the event loop reached step 1, the element was in
that Document"

Does it mean the style sheet blocks scripts only if it's currently being parsed?


Tali
 		 	   		  
_________________________________________________________________
Windows Live: Make it easier for your friends to see what you?re up to on Facebook.
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_2:092009
Received on Tuesday, 27 October 2009 23:59:14 UTC

This archive was generated by hypermail 2.4.0 : Wednesday, 22 January 2020 16:59:18 UTC