Hello All,
I would like to build function when user click on list result and output console.log(‘test’);
export default class ResultList extends Component {
clickableItem() {
console.log(‘test’);
}
   render() {
        return (
             <li className="list-item">
                 <a href="#" onClick={ this.clickableItem.bind(this) }> Show</a>
            </li>
        );
  }
}
Error happen: Uncaught TypeError: Cannot read property ‘bind’ of undefined
Any idea help in this case, very very welcome