[wp-trac] [WordPress Trac] #34292: Support for DNS Prefetching & Prerender
WordPress Trac
noreply at wordpress.org
Tue May 17 11:17:15 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 moonomo):
Replying to [comment:11 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.
Looks pretty neat- thanks for this!
--
Ticket URL: <https://core.trac.wordpress.org/ticket/34292#comment:12>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform
More information about the wp-trac
mailing list