The newURL property is a read-only property and is used to return URL of the document after hash i.e, anchor part has been changed. It contains the URL to which we navigated. For getting the URL from which we navigated away, we use the oldURL property.
Its syntax is:- event.newURL
Its return is:- a string containing URL that was navigated to