Corrected function call
The function created isn't the function that was called. I corrected the function call
This commit is contained in:
committed by
GitHub
parent
c93a5b9215
commit
86d5f9b3fa
@ -18,7 +18,7 @@ const addEventListenerAll = (targets, type, listener, options, useCapture) => {
|
||||
```
|
||||
|
||||
```js
|
||||
addAllEventListeners(document.querySelectorAll('a'), 'click', () =>
|
||||
addEventListenerAll(document.querySelectorAll('a'), 'click', () =>
|
||||
console.log('Clicked a link')
|
||||
);
|
||||
// Logs 'Clicked a link' whenever any anchor element is clicked
|
||||
|
||||
Reference in New Issue
Block a user