Skip to content
PHP Ecosystem
Explore

HasFetchpriority

API reference › HTML Attribute › HasFetchpriority

traitUIAwesome\Html\Attribute\HasFetchpriority
Sourcesrc/HasFetchpriority.php
Used by 3 types

Provides an immutable API for the fetchpriority attribute.

See also: https://developer.mozilla.org/en-US/docs/Web/HTML/Reference/Attributes/fetchpriority.

MethodDescriptionDefined by
fetchpriority()Sets the fetchpriority attribute.HasFetchpriority
public function fetchpriority(string|UnitEnum|null $value): static

Sets the fetchpriority attribute.

Hints the browser about the fetch priority for the resource.

Parameters

ParameterTypeDescription
$valuestring|UnitEnum|nullFetch priority token, or null to remove the attribute.

Returns

static: New instance with the updated fetchpriority attribute. Fetchpriority for predefined enum values.

Throws