react-svg-morph
react-svg-morph copied to clipboard
easing function with MorphReplace
Can i change the easing function in MorphReplace?
i have this code but not work...
import { MorphReplace } from 'react-svg-morph';
import { easeInOutCubic } from 'react-svg-morph/lib/utils/easing';
renderLine() {
return (
<MorphReplace
easing={easeInOutCubic}
width={100}
height={100}
duration={1000}
rotation="none"
>
{this.state.isOpen ? <OpenCurvedSVG key="open" /> : <LineSVG key="close" />}
</MorphReplace>
);
}
have the same issue, @sarovin you found a solution for that?
@gorangajic Thanks, could you help to check whether the easing function work or not now? Thanks so much ;)
@tomsvogel @sarovin Have you solve the easing problem yet? Thanks.
@gorangajic @tomsvogel @sarovin I noticed in MorphReplace.js last second line, it ends with a " , " . Is it supposed to have " easing: function(t) { return t; } " as the last object?