Stupid Question 135: What are vendor-specific CSS property prefixes?
A few posts ago I explained how you can use a grid to lay out a Windows Store App, with C# and XAML, and Html and JS. The Html and JS implementation uses vendor specific tags/properties for the css for Internet Explorer, the -ms-grid (read the article here: WinRT comparison JS/Html and C#/XAML: Using a grid for app layout ). I didn’t however explain what they are, so let’s do that.
vendor-specific CSS property prefixes explained
Those that make browsers are called vendors , definition of vendor is: One that sells or vends (vending is basically selling).
Vendors can extend the current CSS by adding their own stuff to it, basically like I would do with an extension method in C# or prototyping in JavaScript, category in Objective C and so. But it’s only their extension, and will only work in the browser they supply, and therefore we call these properties vendor specific. They all follow a specific naming convention that goes like this:
two words that start with a - (dash) or _ (underscore).
Here is an example: -ms-grid
Why this convention? This is to avoid naming conflicts between different vendors and the default CSS.
Comments
Last modified on 2013-01-25