2
var linksMenu = document.querySelectorAll(".links-menu");
for (var i = 0; i<linksMenu.length; i++) {
linksMenu[i].addEventListener("click",function() {
console.log(linksMenu[i]);
});
}
I cannot show the position it was clicked on, in the case, it appears as Undefined.
However, if you put any console.log, it works exactly in the clicked position, so it’s functional.