<map><area router-href + PushState :: Whole page reloads
I'm submitting a bug report
-
Library Version:
[email protected] (according to
npm list)
Please tell us about your environment:
-
Operating System: Windows 10
-
Node Version: 6.9.4
- NPM Version: 3.10.10
- Aurelia CLI OR JSPM OR Webpack AND Version CLI 0.30.1
-
Browser: Chrome 59 | Edge 15.15063
-
Language: ESNext
Current behavior:
Router is configured to use the Push State API.
If one clicks on the <area> link, the whole page will reload. Nevertheless, Aurelia route to the right template. So I assume PushState is not used.
app.js:
export class App {
configureRouter(config, router) {
config.options.pushState = true;
// [...]
p1.html:
<template>
<img src="p1.png" width="1280" alt="p1" usemap="#p1map">
<map id="p1map" name="p1map">
<area alt="p2" route-href="route: p2" shape="rect" coords="860,2830,1010,2860"/>
</map>
</template>
Expected/desired behavior:
The app navigates in-app to the destination template/page (without reloading the website) and uses PushState.
Unfortunately, I cannot provide a runnable gist because PushState does not seem to work on GistRun:
VM564 aurelia.js:14638 ERROR [app-router] Router navigation failed, and no previous location or fallbackRoute could be restored.
- What is the motivation / use case for changing the behavior? This bug circumvents many advantages of a SPA.