Vuepress: Back button needs two clicks to go back

Created on 10 May 2018  路  4Comments  路  Source: vuejs/vuepress

While reporting Bug #387 , I noticed another problem:

  • Your OS: Xubuntu 18.04
  • Node.js version: v10.0.0
  • VuePress version: 0.8.4
  • Browser version: Firefox 59.0.2 (or chromium-browser 65.0.3325.181)
  • Is this a global or local install: global
  • Which package manager did you use for the install: npm

Steps to reproduce:

mkdir bug 
mkdir bug/subdir
cd bug

echo "# Link to [subdir](subdir)" > README.md
echo "# Subdirectory page" > subdir/README.md

vuepress dev

firefox http://localhost:8080    # same result with chromium-browser
  • Click on "subdir"
  • Click the browser's back button

Result:

  • The first click only changes the browsers window title. Second click needed to go back.

Expected:

  • Go back after the first click.
contribution welcome bug

Most helpful comment

Indeed reproduced it, looks like a bug of vue-router, will sync later.

All 4 comments

Indeed reproduced it, looks like a bug of vue-router, will sync later.

As an added note, this does not happen when you use subdir/, so the issue seems to be that the redirect for the trailing / is getting pushed to the history stack when it shouldn't be.

We're closing this issue as stale as it's more than 20 days without activity, and without an associated Pull Request. Please feel free to continue discussion. We'll reopen this issue if anything actionable is posted.

This bug is still happening for me as well. If I omit the trailing slash on a link to a subdirectory (e.g. [See all announcements](/announcements), then I have to hit the back button twice. If I add the trailing slash, I only have to go back once.

I'm also a bit confused about the workflow here. The maintainer reproduced and confirmed the bug, committed to personally fixing it, then closed the issue because of a lack of activity?

Was this page helpful?
0 / 5 - 0 ratings

Related issues

sankincn picture sankincn  路  3Comments

ederchrono picture ederchrono  路  3Comments

shaodahong picture shaodahong  路  3Comments

AMontagu picture AMontagu  路  3Comments

zeke picture zeke  路  3Comments