function Htmx::indicator
Creates a `data-hx-indicator` attribute.
This attribute instructs HTMX which element should receive the htmx-request class on during the request.
Parameters
string $selector: The element CSS selector value. Selector may be prefixed with `closest`.
Return value
static Returns this object to allow chaining methods.
See also
https://htmx.org/attributes/hx-indicator/
File
-
core/
lib/ Drupal/ Core/ Htmx/ Htmx.php, line 1067
Class
- Htmx
- Presents the HTMX controls for developers to use with render arrays.
Namespace
Drupal\Core\HtmxCode
public function indicator(string $selector) : static {
$this->createStringAttribute('hx-indicator', $selector);
return $this;
}
Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.