Pushstate custom JS is refreshing content page (Node) is that expected on node?

HI all,

I’m changing the URL path with pushstate, and an on:click event on the page. This is so I can change the UUID and fetch new data based on this, without needing to go to a new URL.

However, it seems to be acting as if I am going to a new URL, and refreshing the content page.

Being new to using pushstate, is this to be expected? and is there a way around this to avoid the page refresh/flicker.

Thanks!