- From: Jatinder Mann <jmann@microsoft.com>
- Date: Tue, 20 Aug 2013 23:09:22 +0000
- To: "'public-web-perf@w3.org'" <public-web-perf@w3.org>
- Message-ID: <36d3fd2288ab42dea24000e773eb9dea@BLUPR03MB065.namprd03.prod.outlook.com>
Based on feedback from the working group, I have made some updates to the Resource Priorities spec, https://dvcs.w3.org/hg/webperf/raw-file/tip/specs/ResourcePriorities/Overview.html: - Added the postpone attribute The use case of never downloading a resource until its viewable by the user seems compelling from a system resources, server resources, and user bandwidth (e.g., mobile user) scenarios, but it does feel functionally different from the lazyload concept, where in cases of network contention connections are given to higher priority resources. I've added a new postpone attribute to describe the case where we don't want resources to be downloaded if they aren't formatted to be visible or are not in the viewport. This attribute only applies to resources that can be laid out. - Defined script download and execution behavior For the script element, I've added more details on its expected execution behavior. The lazyload attribute delays downloading script in network contention scenarios, and will execute the script asynchronously soon as its available. Lazyload in this way behaves more closely to async than defer. I was initially considering changing the script execution behavior based on whether lazyload is used with defer or async (e.g., <script async lazyload> or <script defer lazyload>, but for now I have left it to be more closely aligned with async. As defer scripts take ordering into account, we would need to create a separate queue for <script lazyload defer> scripts, otherwise any <script defer> that came after a <script lazyload defer> would implicitly be lazyloaded as well. - Added MUST clauses There was feedback that if the spec only has optional clauses, there will be very little to test. I have updated the spec to have MUST clauses, but have left the definition of the network resource contention and visibility generic enough that User Agents can choose to optimize here as needed. - Updated events behavior The load event of the Document isn't delayed by resources with lazyload or postpone. In case developers are interested in tracking when all of their lazyloaded resources have actually loaded, I have specified a lazyloaded event that fires at that time. I haven't provided a similar event for postpone as I am assuming most developers would want to track those using load events on the element directly. - Added both IDL and content attributes I've made the attributes both IDL and content attributes, to be consistent with other similar attributes and help with feature detection. - Added use cases to introduction section I have added more use cases and examples to the introduction section. Please review and provide feedback. Thanks, Jatinder
Received on Tuesday, 20 August 2013 23:09:53 UTC