This flag exists to answer the question: “Is there a way with WinJS.Navigation.navigate to navigate to a new page without adding an entry in the history?” If you look in WinJS’s base.js, you’ll find that when this flag is true, WinJS skips the step of adding whatever page you’re navigating to to the nav stack. That flag itself exists in WinJS to apparently prevent the initial page in an app from being entered into the history, but as it’s implemented you can use it also for this more general purpose. Just be sure to set it to false when you want pages to be added to the history again.



  1. philk
    Posted April 23, 2013 at 7:45 pm | Permalink

    And why was it not called addtohistory then instead?

    • Posted April 23, 2013 at 7:54 pm | Permalink

      Legacy…usually when something like this is found to serve multiple purposes in mid-cycle, it’s not necessarily a high priority to rename it. Devs tend to get skitterish about seemingly insignificant changes, as it spawns a test cycle and other work that means not doing something else instead. So it’s a matter of cost and prioritization, for better or worse.