On this page
apply_filters( 'wp_resource_hints', array $urls, string $relation_type )
Filters domains and URLs for resource hints of relation type.
Parameters
$urlsarray-
Array of resources and their attributes, or URLs to print for resource hints.
...$0array|stringArray of resource attributes, or a URL string.hrefstringURL to include in resource hints. Required.asstringHow the browser should treat the resource (script,style,image,document, etc).crossoriginstringIndicates the CORS policy of the specified resource.prfloatExpected probability that the resource hint will be used.typestringType of the resource (text/html,text/css, etc).
$relation_typestringThe relation type the URLs are printed for, e.g.'preconnect'or'prerender'.Source
File:
wp-includes/general-template.php. View all references$urls = apply_filters( 'wp_resource_hints', $urls, $relation_type );Related
Used By
Used By Description wp_resource_hints() wp-includes/general-template.php Prints resource hints to browsers for pre-fetching, pre-rendering and pre-connecting to web sites.
Changelog
© 2003–2022 WordPress Foundation
Licensed under the GNU GPLv2+ License.
https://developer.wordpress.org/reference/hooks/wp_resource_hints