You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

readme.md 973 B

3 years ago
123456789101112131415161718192021222324252627282930313233343536373839404142
  1. [![Build Status](https://travis-ci.org/cssinjs/css-vendor.svg?branch=master)](https://travis-ci.org/cssinjs/css-vendor)
  2. ## CSS vendor prefix detection and property feature testing.
  3. ### Vendor prefixes
  4. ```javascript
  5. console.log(cssVendor.prefix.js) // e.g. WebkitTransform
  6. console.log(cssVendor.prefix.css) // e.g. -webkit-transform
  7. ```
  8. ### Property support feature test
  9. `cssVendor.supportedProperty(prop)`
  10. Test if property is supported, returns false if not. Returns string if supported. May add a vendor prefix if needed.
  11. ```javascript
  12. console.log(cssVendor.supportedProperty('animation')) // e.g. -webkit-animation
  13. ```
  14. ### Value support feature test
  15. `cssVendor.supportedValue(prop, value)`
  16. Test if value is supported, returns false if not. Returns string if supported. May add a vendor prefix if needed.
  17. ```javascript
  18. console.log(cssVendor.supportedValue('display', 'flex')) // e.g. -webkit-flex
  19. ```
  20. ## Run tests
  21. ```bash
  22. npm i
  23. npm test
  24. ```
  25. ## License
  26. MIT