0

I am using NextJS routing, but when I try to use document.referrer in my code, it does not return any value. How can I resolve this issue?

I am using the router.events.on method to listen for changes in navigation, but I haven't found a way to retrieve the referrer value.

Jonas
  • 121,568
  • 97
  • 310
  • 388
Vishal
  • 17
  • 6

1 Answers1

0

The HTTP Referer header has been misspelled since 1996. Use document.referer instead.

stdunbar
  • 16,263
  • 11
  • 31
  • 53