If I have an event listener and want to use a click event to target a function, would the preferred way to define that function be outside of the scope or can I make it nest