I am working with useEffect and want to figure out how to call a different API when an onClick event happens. When my page loads the following is run:
useEffect((