Skip to content

Instantly share code, notes, and snippets.

@fakiolinho
Last active March 13, 2018 18:53
Show Gist options
  • Save fakiolinho/9990fa8ae89bc8572dfcfd1161904955 to your computer and use it in GitHub Desktop.
Save fakiolinho/9990fa8ae89bc8572dfcfd1161904955 to your computer and use it in GitHub Desktop.
import React, { Component } from 'react';
export default class Options extends Component {
handleAdd = () => {
console.log('add');
};
handleEdit = () => {
console.log('edit');
};
handleDelete = () => {
console.log('delete');
};
render() {
return (
<ul>
<li>
<button onClick={this.handleAdd} className="add">Add</button>
</li>
<li>
<button onClick={this.handleEdit} className="edit">Edit</button>
</li>
<li>
<button onClick={this.handleDelete} className="delete">Delete</button>
</li>
</ul>
);
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment