Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

This is a decent work-around. There's two reasons why it's an inferior solution:

1. It slows down rendering or causes a potentially huge reflow when the feature support classes are added.

2. The specificity of body.unsupported-border-radius .box is greater than the original rule, and this is going to cause issues with the rule ordering.



Yeah, definitely on #1 -- it's a performance hassle.

re: #2, a higher level of specificity acts like a ham-fisted override when the original rule you prefer can't be applied. that seems the right order of precedence to me.

EDIT: i see what you mean now. an @unsupported attribute as you describe acts like an either-or. the javascript solution i'm talking about cascades like a "this-and-also-this".




Consider applying for YC's Fall 2026 batch! Applications are open till July 27.

Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: