Skip to content

Prevent navigation guard still updates currentChild? #201

@TomStrepsil

Description

@TomStrepsil

I'm experimenting with pager and history.js

I was hoping that by not firing the guard callback, pager could prevent the url changing to a new path, and prevent the old page from being hidden. As it is, although the guard prevents the new page showing, the page-href has already been actioned.

A basic fiddle with the callback not being fired shows that the first page still gets hidden when clicking Page 2. Outside of jsfiddle, the url would be updated to #page2, also.

http://jsfiddle.net/Lc1am4ah/1/

Is there any way to mitigate this? I assume I will otherwise have to "bind to global click" (http://pagerjs.com/demo/#!/navigation/custom_js_when_navigating) to control workflow, which I'm not too keen on.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions