I want to call a post api while changing the checkbox input? Right now i am doing this in the below patter but while Component re-render this api function got called? What