AjaxPageParser icon indicating copy to clipboard operation
AjaxPageParser copied to clipboard

Buggy duplicate pushstate and back button

Open alanontheweb opened this issue 9 years ago • 1 comments

I really like this plugin, and want to continue using it but have spotted 2 significant bugs. I was hoping you could take a look and perhaps offer a fix when possible. It's hard to use in production while these issues are pending.

1)When visiting the demo page - http://terwanerik.github.io/AjaxPageParser/index.html

Refreshing the page several times keeps adding a pushState to the browser's history, making the back button not actually link to the previous page. It shouldn't be adding empty history states like that.

screen shot 2016-08-25 at 8 37 35 pm
  1. Further, when you open the demo in a new tab and navigate to the second page, and then hit "back" on the browser, the address bar gets updated, but the script does not replace the ajax content region.
screen shot 2016-08-25 at 8 42 02 pm

alanontheweb avatar Aug 26 '16 03:08 alanontheweb

Yeah i've been planning a rewrite for this, in vanilla JS, for a while now. When/if i have some free time i'll start work on that, fixing this, and other things, that are wrong with this plugin.

terwanerik avatar Aug 30 '16 11:08 terwanerik