loader¶
The loader
macro is used to render a spinner indicating that something is loading.
Definition¶
Input parameters¶
options¶
object
represents an object of loader options and attributes
Option key | Type | Default | Required | Description |
---|---|---|---|---|
options.ariaLabel | string |
"" | no | aria-label attribute of the loader |
Example¶
In this example we render a basic loader
Example¶
In this example we render a loader with a custom aria label
{% from "@macros/loader.twig" import loader %}
{{ loader({ ariaLabel: 'loader for a list of products' }) }}