Ensuring CSS Validation with Vendor Prefixes
Despite the prevalence of CSS properties like -webkit-border-radius and -moz-box-shadow, validation remains elusive. The CSS3 Syntax module permits vendor prefixes, but actual extensions are not recognized.
Recognizing Vendor Prefixes as Errors
The W3C CSS Validator treats vendor prefixes as errors. To mitigate this, the validator now offers an option to convert errors into warnings.
Activating Warning Mode
Expand the "More Options" section within the validator and enable "Reduce Errors from Vendor Prefixes to Warnings." This allows for validation without penalizing vendor prefix usage.
Imperfect Solution
While warning mode provides some validation, it's crucial to note that vendor prefixes remain non-standard. Therefore, CSS employing them is still technically invalid.
The above is the detailed content of How Can I Validate CSS Code Containing Vendor Prefixes?. For more information, please follow other related articles on the PHP Chinese website!