ianbjorndilling / react-typewriter

A React component for creating typing animations.
MIT License
86 stars 37 forks source link

Hi I used this react-typewriter good, but How to add another sentence? #26

Open DDanggle opened 8 years ago

DDanggle commented 8 years ago

Version

0.4.1

Steps to reproduce

  1. This sentence list is what I had. ['Hello World!', 'Welcome to react-typewriter!', 'React is awesome!']
  2. I want to view order by list after erase it. this is order of example.

'Hello World!' -> erase 'Hello World!' -> 'Welcome to react-typewriter!' -> erase 'Welcome to react-typewriter!' -> ...

done = () => {

    if (this.state.typing === 1) {
      this.setState({ typing: -1 });
    } else if (this.state.typing === -1) {
      this.setState({ typing: 1 });
    }
  }
<TypeWriter typing={typing}
                     onTypingEnd={this.done}
                     reset={this.typed}
                >

How come do i get to reach it?

saulocastillos commented 4 years ago

Any guesses?