Skip to content

Instantly share code, notes, and snippets.

@nadeesha
Created February 10, 2019 00:23
Show Gist options
  • Save nadeesha/4f6df9cb7b55f6e8022af4cebab33451 to your computer and use it in GitHub Desktop.
Save nadeesha/4f6df9cb7b55f6e8022af4cebab33451 to your computer and use it in GitHub Desktop.
// https://github.com/brunnolou/react-morph
<ReactMorph>
{({ from, to, fadeIn, go }) => (
<div>
<a onClick={() => go(1)}>
<strong {...from("title")}>ReactMorph 🐛</strong>
<br />
<p {...from("description")}>Morphing transitions was never so easy!</p>
</a>
<div>
<h1 {...to("title")}>ReactMorph 🦋</h1>
<br />
<h2 {...to("description")}>Morphing transitions was never so easy!</h2>
<a onClick={() => go(0)} {...fadeIn()}>
Back
</a>
</div>
</div>
)}
</ReactMorph>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment