W3C home > Mailing lists > Public > whatwg@whatwg.org > July 2013

Re: [whatwg] Script preloading

From: Bruno Racineux <bruno@hexanet.net>
Date: Thu, 11 Jul 2013 17:25:44 -0700
To: Alex Russell <slightlyoff@google.com>, Jake Archibald <jaffathecake@gmail.com>
Message-ID: <CE048772.6B6D3%bruno@hexanet.net>
Cc: Kyle Simpson <getify@gmail.com>, "whatwg@whatwg.org" <whatwg@whatwg.org>
On browser preloading:

There seems to an inherent conflict between 'indiscriminate' Pre-parsers/
PreloadScanner and "responsive design" for mobile. Responsive designs
mostly implies that everything needed for a full screen desktop is
provided in markup to all devices.



Isn't the Pre-parsers/PreloadScanner's inability to take into account the
display[none:yes] factor be a potential significant blow to 'mobile'
performance.

Use case: What if I have a set of images in an element set as
display:none; only designated to be show on desktop or tablet screens and
not on mobile phone?

What if I have an inline script in that node?


Isn't the PreloadScanner loading a lot more than I need, a problem here?

In addition to the need to preload, with responsive design taken into
consideration, and for lack of not being able to remove part of the <body>
before the browser parses the document. I see an increasing potential need
for the ability to indicate to the browser not to load selective assets
before DOMReady and suppress such preload.

Bruno


On 7/11/13 8:23 AM, "Alex Russell" <slightlyoff@google.com> wrote:

>Here's the Plus URL without the googler cruft:
>
>    https://plus.google.com/u/1/+IlyaGrigorik/posts/8AwRUE7wqAE
>
>
>On Thu, Jul 11, 2013 at 3:47 PM, Jake Archibald
><jaffathecake@gmail.com>wrote:
>
>> On 10 July 2013 17:37, Jake Archibald <jaffathecake@gmail.com> wrote:
>> > On 10 July 2013 16:39, Kyle Simpson <getify@gmail.com> wrote:
>> >> I personally don't care about scripts being discoverable by
>> pre-parsers. I
>> >> have done testing and am not convinced that something appearing
>>earlier
>> (in
>> >> markup) leads to better performance than allowing my script loading
>> logic to
>> >> load things when I want, and just relying on the browser to do that
>>as
>> >> quickly as possible.
>> >
>> >
>> > Pre-parsers can kick in before a page is actually opened, but script
>> cannot
>> > be executed. Let me dig up some numbers on the benefits of this &
>>report
>> > back.
>>
>> Here it is:
>> https://plus.sandbox.google.com/+IlyaGrigorik/posts/8AwRUE7wqAE
>> ~20% improvement.
>>
Received on Friday, 12 July 2013 00:27:07 UTC

This archive was generated by hypermail 2.4.0 : Wednesday, 22 January 2020 17:00:03 UTC