Skip to content

Instantly share code, notes, and snippets.

@fakiolinho
Last active March 13, 2018 18:54
Show Gist options
  • Select an option

  • Save fakiolinho/64302138f40cfc37ae496e27c9df913d to your computer and use it in GitHub Desktop.

Select an option

Save fakiolinho/64302138f40cfc37ae496e27c9df913d 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}>Add</button>
</li>
<li>
<button onClick={this.handleEdit}>Edit</button>
</li>
<li>
<button onClick={this.handleDelete}>Delete</button>
</li>
</ul>
);
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment