Skip to content
This repository has been archived by the owner on Nov 1, 2022. It is now read-only.

easing function with MorphReplace #21

Open
sarovin opened this issue Dec 19, 2016 · 4 comments
Open

easing function with MorphReplace #21

sarovin opened this issue Dec 19, 2016 · 4 comments

Comments

@sarovin
Copy link

sarovin commented Dec 19, 2016

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>
    );
  }
@tomsvogel
Copy link

have the same issue, @sarovin you found a solution for that?

@jefflung
Copy link

jefflung commented Mar 6, 2018

@gorangajic Thanks, could you help to check whether the easing function work or not now? Thanks so much ;)

@jefflung
Copy link

jefflung commented Mar 7, 2018

@tomsvogel @sarovin Have you solve the easing problem yet? Thanks.

@jefflung
Copy link

jefflung commented Mar 7, 2018

@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?

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants