Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
let flattened = Object.keys(style).reduce((accum, key) => {
if (Array.isArray(style[key])) {
accum[key] = style[key].join(`; ${processStyleName(key)}: `)
} else if (
Object.prototype.toString.call(style[key]) === '[object Object]'
) {
accum[key] = expandCSSFallbacks(style[key])
} else {
accum[key] = style[key]
}
return accum
}, {})
// todo -