Note that there are some explanatory texts on larger screens.

plurals
  1. PODurandal SPA on iPad goes to browser when navigating
    primarykey
    data
    text
    <p>Created ASP.Net SPA using Durandal. Added a forms login page that is hit prior to the SPA. When accessed on an iPad and saved to Home screen it opens like a native app, I can login and still stays in same window when it opens the SPA. BUT as soon as I navigate to another route it opens Safari instead.</p> <p>Is there something I'm missing or any possible way I can avoid this, it would be nice if I can keep it looking like a native app.</p> <p>EDIT: As required logic from shell.js from Durandal viewmodels folder:</p> <pre><code>define(['plugins/router', 'durandal/app'], function (router, app) { return { router: router, activate: function () { router.map([ { route: '', title:'Actions', moduleId: 'viewmodels/actions', nav: true }, { route: 'welcome', title:'Welcome', moduleId: 'viewmodels/welcome', nav: true }, { route: 'flickr', moduleId: 'viewmodels/flickr', nav: true }, { route: 'clients', moduleId: 'viewmodels/clients', nav: true }, { route: 'client/:id', moduleId: 'viewmodels/client', nav: false } ]).buildNavigationModel(); return router.activate(); }, attached: function () { $("#logoff").show(); } }; }); </code></pre> <p>You can simply create a new Application in VS 2012+ using the downloadable Durandal SPA template from asp.net site.</p> <p>Logic from shell.html:</p> <pre><code>&lt;ul class="nav" data-bind="foreach: router.navigationModel"&gt; &lt;li data-bind="css: { active: isActive }"&gt; &lt;a data-bind="attr: { href: hash }, html: title"&gt;&lt;/a&gt; &lt;/li&gt; &lt;/ul&gt; </code></pre>
    singulars
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload