1
0
Fork 0
mirror of https://github.com/haml/haml.git synced 2022-11-09 12:33:31 -05:00

Explain special case of data- and aria- attributes (#1095)

This commit is contained in:
Daniel Diekmeier 2022-10-03 06:58:22 +02:00 committed by GitHub
parent d92a5aa83b
commit 0eb3cf6978
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -294,7 +294,19 @@ or using `true` and `false`:
%input(selected=true)
This feature works only for attributes that are included in
[`Haml::AttributeBuilder::BOOLEAN_ATTRIBUTES`](lib/haml/attribute_builder.rb).
[`Haml::AttributeBuilder::BOOLEAN_ATTRIBUTES`](lib/haml/attribute_builder.rb),
as well as `data-` and `aria-` attributes.
%input{'data-hidden' => false}
%input{'aria-hidden' => false}
%input{'xyz-hidden' => false}
will render as:
<input>
<input>
<input xyz-hidden='false'>
<!-- The title to the next section (Prefixed Attributes) has changed. This
<a> tag is so old links to here still work. -->