Hacker News new | ask | show | jobs
by jsh7 3783 days ago
Try this: `class extends Component { foo = () => { console.log('this was bound at construction time'); }; render() { return <SubComponent foo={this.foo} />; } }` This only works if you have stage-1 class properties enabled though.