[wp-trac] [WordPress Trac] #34292: Support for DNS Prefetching & Prerender

WordPress Trac noreply at wordpress.org
Mon May 16 23:05:33 UTC 2016


#34292: Support for DNS Prefetching & Prerender
--------------------------------------+--------------------------
 Reporter:  bhubbard                  |       Owner:
     Type:  feature request           |      Status:  new
 Priority:  normal                    |   Milestone:  4.6
Component:  Script Loader             |     Version:
 Severity:  normal                    |  Resolution:
 Keywords:  has-patch has-unit-tests  |     Focuses:  performance
--------------------------------------+--------------------------

Comment (by voldemortensen):

 Replying to [comment:10 swissspidy]:
 > That's awesome! Happy to work more on this.
 >
 > Some notes:
 >
 > * The patch is for DNS prefetching only, without prerender. If we do
 this, we should probably add both
 > * Is a filter enough for this, or do we need `add_*`/ `remove_*` helper
 functions? (I don't think we need them)
 > * Is `array_unique()` enough? IIRC, Jetpack has stricter rules for the
 added URLs

 34292.2.diff includes prerendering and unit tests for that. I think a
 filter is good enough here. If there is demand we can add helper functions
 later without back compat worries no? And I think `array_unique` is good
 enough here. We don't care about array keys. And I don't think its
 terrible if someone inadvertently puts a non-url there. Either a bad dns
 lookup or a 404/couldn't load type page will be cached in the background.

--
Ticket URL: <https://core.trac.wordpress.org/ticket/34292#comment:11>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform


More information about the wp-trac mailing list