I'm working with css and I have tried to add an element 'before' to my div like an arrow. Is there any way to achieve it? I tried pseudo :before but there are three of them (::before(2), :before and ::before). They make me so confuse, what are differences in between?
The CSS spec on content describes all three syntaxes.
:before
-- outdated syntax for pseudo elements. Use if older browser support is needed such as IE8. IE9 supports the new syntax. It also seems like iOS Safari does not support the new syntax
::before
-- new pseudo element syntax. This is equivalent to ::before(1)
::before(n)
-- used to create multiple before
elements that can be before other ::before
s. Details are in the same spec.If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With