Skip to content

Instantly share code, notes, and snippets.

@dbismut
Last active April 9, 2018 07:57
Show Gist options
  • Select an option

  • Save dbismut/431d21d328d2ee8d417c60e54589f869 to your computer and use it in GitHub Desktop.

Select an option

Save dbismut/431d21d328d2ee8d417c60e54589f869 to your computer and use it in GitHub Desktop.
Part 2 - Calculating destination style for entering transition
onEnter = () => {
/* same code */
this.from = this.getPreviewStyleAndPosition();
this.to = {
top: 0,
height: window.innerHeight,
width: document.body.offsetWidth,
borderRadius: 0
};
};
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment