logoalt Hacker News

recursiveyesterday at 10:40 PM1 replyview on HN

The selectors are not different. Whatever problems you have applying styles to html elements also exist in react.


Replies

zarzavattoday at 5:49 AM

Yes they are.

For example, Blink/Webkit allow <meter> and <progress> to be styled. Firefox does not support those pseudoclasses so you can't style those elements cross browser.

Then there is <input type="range">

    Blink, Webkit:
    
    ::-webkit-slider-thumb
    ::-webkit-slider-runnable-track
    
    Firefox:
    
    ::-moz-range-thumb
    ::-moz-range-track
    ::-moz-range-progress
If I build a meter or progress bar in React, I can easily style it and because it uses divs and not wonky pseudoclasses then it looks the same in every browser.