private handleClick = event => {
const params = new URLSearchParams(window.location.search);
let Useridval = params.get('ID');
console.log(event.currentTarget.id);
this.setState({ count: this.state.count + 1 })
};
private handleClick = event => {
const params = new URLSearchParams(window.location.search);
let Useridval = params.get('ID');
console.log(event.currentTarget.id);
this.setState({ count: this.state.count + 1 })
};
Know the answer? Post it — somebody with the same question will find it here.
Sign in to answer this question
It is the same account you read, post and publish with — and you will come straight back to this page.
Rupesh KahanePosted Jun 6, 2022, 6:24 AM
https://contactmentor.com/react-increment-counter-hooks/