BASELINE NowYouCanUse.com
Limited Availability CSS
id: attr

attr()

The attr() CSS function, in the context of any property, returns the value of an attribute of an HTML element, with the option to return it as a specific type or unit. You can set a default value for missing or invalid attributes.
Baseline Status: This feature is currently Limited and is missing in at least one major browser engine.
Desktop Browser Engine Support
Google Chrome
133
Supported
Mozilla Firefox
155
Supported
Apple Safari
Unsupported
Microsoft Edge
133
Supported
Mobile Browser Engine Support
Chrome Android
133
Firefox Android
155
Safari iOS
Specifications and References