Modern CSS

# The attr() function
Three practical use cases

The attr() CSS function is used to retrieve the value of an attribute of the selected element and use it in a property value, similar to how the var() function substitutes a custom property value.

01

## Custom Progress Bars

Total Progress
Customer Spending
Project Progress
02

## Staggered delays

- ✓ Example Item 1 Dolor sit amet consectetur. Ipsum
- ↗ Example Item 2 Sed do eiusmod tempor. Dolor
- ● Example Item 3 Labore et dolore magna. Amet

03

## View transitions

Article 1 Read ↗
Article 2 Read ↗
Article 3 Read ↗