Popstate event listener not working with app router
Unanswered
Siamese Crocodile posted this in #help-forum
Siamese CrocodileOP
Hi I want to listen for history changes and I am using popstate listener but when I click nextjs links or call router.push listener is not triggered.
addEventListener("popstate", () => console.log("POPSTATE"))