Pass as props
function App() {
const handleMrFlibble = e => {
console.log(`Who'll clear up the mess?`)
}
return (
<Main>
<MyButton onClick={handleMrFlibble}>Fry</MyButton>
</Main>
)
}Pass as props
function App() {
const handleMrFlibble = e => {
console.log(`Who'll clear up the mess?`)
}
return (
<Main>
<MyButton onClick={handleMrFlibble}>Fry</MyButton>
</Main>
)
}