What does it mean when a css property starts with a dash?
conventions, css, naming-conventions
Solution
`-webkit-` and `-moz-` here are called vendor prefixes; they generally indicate a browser-specific feature of CSS, or one that’s under development/still a draft and can’t be considered a standard yet. When these features are used “ahead of time”, the only way to make it work in every browser is sometimes to provide a different rule with a different prefix for each one — that’s what you see in the project. The idea is that eventually, though, the feature will be standardized, browsers will drop the prefixes, and life will go on.
`-webkit-gradient`, for example, was the first way to define a gradient in CSS, but was replaced by a completely different `linear-gradient` and `radial-gradient` syntax.
A convenient way to find out what browsers support a certain feature and what prefixes you need if you’re using it before a definitive standard or global unprefixed browser support is Can I Use….
Some common prefixes are:
- `-webkit-` for WebKit-based browsers, including Chrome/Chromium and Safari
- `-moz-` for Firefox
- `-ms-` for Internet Explorer (9 and up)
- `-o-` for Opera (pre-WebKit)
Problem
I just downloaded a css file from this website and it contains properties such as `-webkit-transform` and `-moz-transform`. What does the dash mean and under what circumstances is it required? For the nity grity does the phrase "vendor prefix" refer to the - or the content between the - and - (exuding the - and -) or the content between the - and - (including the - themselves)? In other words does vender prefix refer to the dash itself or only the content between the dashes or the dashes with the content between them?