DEV Community

André
André

Posted on

3

Angular Single Class Binding

For today, I learned that there is a thing called "Class Binding" in Angular that allows me to have CSS override the existing Styling based on conditions.

<div class="normal" [class.fullscreen]="isFullscreen">...</div>
Enter fullscreen mode Exit fullscreen mode

My usecase is that a clicked div gets a different styling to highlight a selection!

Top comments (0)

Postmark Image

Speedy emails, satisfied customers

Are delayed transactional emails costing you user satisfaction? Postmark delivers your emails almost instantly, keeping your customers happy and connected.

Sign up

👋 Kindness is contagious

Please leave a ❤️ or a friendly comment on this post if you found it helpful!

Okay