Jump to content
Search Community

Will Howard

Members
  • Posts

    1
  • Joined

  • Last visited

Posts posted by Will Howard

  1. In case anybody's still looking for a super simple example, here's a basic component with an animated gsap title:

     

    import React, { Component } from 'react';
    import { TweenMax } from 'gsap';
    
    export default class AnimatedTitle extends Component {
      componentDidMount() {
        TweenMax.to(this.title, 3, { x: 300 });
      }
    
      render() {
        return (
          <h1 ref={h1 => { this.title = h1; }} >Animated Title</h1>
        );
      }
    }

     

    • Like 2
×
×
  • Create New...