Skip to content

Instantly share code, notes, and snippets.

@dance2die dance2die/Greeting.js
Last active Sep 15, 2018

What would you like to do?
class Greeting extends Component {
hello = id => console.log(`hello world! - ${id}`);
componentDidMount() {
const id = shortid.generate();
setInterval(e => this.hello(id), 1000);
componentWillUnmount() {
console.log("Greeting unmounted...");
render() {
return (
<Link to="/main">Go to Main Page</Link>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.