Thoughts on Bootstrap 5.2.0 CSS Variables?

Just curious as to people’s thoughts on the new (as of BS 5.2) CSS variables in Bootstrap. Have you found them useful? Unnecessary? No opinion either way?

1 Like

I see nobody has chimed in on this, so I guess I’ll be the first. My initial impressions are that they are just adding an unnecessary level of complication to the CSS. Maybe I’m not seeing the advantage in having 20 CSS rules for the .navbar class that are all preceded by --bs-navbar-(whatever.)

Anyone else have an opinion? Maybe someone can explain what I’m missing, because I don’t see the big advantage here.

It’s more easy to customize theme in BSS with CCS variables.

I hear that just around the corner (5.3) light dark themes will be possible and I am sure css var will be driving that home to the winners circle. So much that has changed in 5 that there could be 15 topics on it all… :soccer:

1 Like

I guess since I don’t really use “themes” in my work, this benefit is lost on me.

THIS will be very cool. I build some template-style websites for martial arts schools, and I would love it if I could offer a particular design that could easily be switched from “light” to “dark.”