Dynamically add vendor flexbox prefixes to CSS style dictionaries
$ npm install --save preflex
// In Safari
var prefix = require('preflex')
prefix({flex: 1})
//=> {flex: 1, webkitFlex: 1}
prefix({display: 'flex'})
//=> {display: '-webkit-flex'}
Returns a copy of the original object with both the standard flexbox property and the prefixed version.
Required
Type: object
An object containing CSS style properties. Keys should be camel cased, e.g. flex-direction
should be flexDirection
.
MIT © Ben Drucker