tweening engine for Typescript
npm i unplugin-vue-cssvars -D
Or
yarn add unplugin-vue-cssvars -D
Or
pnpm add unplugin-vue-cssvars -D
import SmokeDistance from 'b-tween';
const smoke = new SmokeDistance({
from: {
left: 0
},
to: {
left: 700
},
duration: 500,
easing: 'bounceOut',
onUpdate: (keys) => {
// You can do everything with keys
block.style.left = keys.left + 'px';
}
});
smoke.start();