I am relatively new to programming and am having difficulty understanding what " () => " means when used as a parameter.
I couldn't find any solution online to explain what this meant and I was quite confused when I saw it because I learned that the second parameter of the addEventLister() method is meant for your function.
addEventListener('resize', () => {
canvas.width = innerWidth
canvas.height = innerHeight
})
So my assumption is its a short hand term to write a function, but correct if I'm wrong? I want to because I seen it in multiple lines of code now and would appreciate an explanation.