keyframe-transpose
v1.0.2
Published
Convert object keyframe input to array
Downloads
4
Readme
keyframe-transpose
Convert object keyframe input to array
Usage
const keyframeTranspose = require('keyframe-transpose')
keyframeTranspose({
opacity: [0.5, 2, 1],
transform: ['scale(0.5)', 'scale(1)']
})
Output:
[
{ offset: 0, opacity: 0.5, transform: 'scale(0.5)' },
{ offset: 0.5, opacity: 2 },
{ offset: 1, opacity: 1 , transform: 'scale(1)' },
]