To detect DOM differences that reach the 'head' or 'body' elements the fix adds temporarily 'id' attributes to these elements if they're missing. By doing this the diff process will stop before reaching the 'html' element.
The 'body' update is applied properly by the JSF bridge as long as the update will look like:
<update id="javax.faces.ViewBody"><![CDATA[<body>.......</body>]]></update>
The expected 'head' update looks similar:
<update id="javax.faces.ViewHead"><![CDATA[<head>.......</head>]]></update>
Unfortunately the update is not handled currently (JSF 2.0.2) by JSF. In the future we could bypass the 'head' level update by sending 'eval' commands back to the bridge. These code sent can modify dynamically the existing head element using other JS APIs. See:
http://www.hunlock.com/blogs/Howto_Dynamically_Insert_Javascript_And_CSS
http://www.hunlock.com/blogs/Totally_Pwn_CSS_with_Javascript
To detect DOM differences that reach the 'head' or 'body' elements the fix adds temporarily 'id' attributes to these elements if they're missing. By doing this the diff process will stop before reaching the 'html' element.
The 'body' update is applied properly by the JSF bridge as long as the update will look like:
<update id="javax.faces.ViewBody"><![CDATA[<body>.......</body>]]></update>
The expected 'head' update looks similar:
<update id="javax.faces.ViewHead"><![CDATA[<head>.......</head>]]></update>
Unfortunately the update is not handled currently (JSF 2.0.2) by JSF. In the future we could bypass the 'head' level update by sending 'eval' commands back to the bridge. These code sent can modify dynamically the existing head element using other JS APIs. See:
http://www.hunlock.com/blogs/Howto_Dynamically_Insert_Javascript_And_CSS
http://www.hunlock.com/blogs/Totally_Pwn_CSS_with_Javascript