Open sabicalija opened 4 years ago
I just saw the router-link to the index page in the response (Chrome, Network Tab).
This answers one question. I understand now why the link was displayed with the 2. link.
But still, it's not clear why it is not working even though a response is received from the server.
Bug report
We need a hook in the vue router before a site is requested from the server, because we want to achieve case insensitive routing. From the documentation of vue router we found the
beforeEach
hook, which should be called before every routing request, when installed globally. We installed a simple hook function, for testing purposes, usingenhanceApp.js
, which logs some routing information to the console.Steps to reproduce
We deployed a test release. When opening the first link, log messages are printed to the console from the
beforeEach
hook. When opening the second, however, a404
is received and no log messages printed, thus nobeforeEach
gets ever executed.What is expected?
The documentation of
vue-router
indicates that routing should be possible case insensitively. However, we would expect the server to send a404
when a resource is not available. But we're unsure if path matching is performed case sensitive or insensitive at the server. The point is, we can't change the current server setup/configuration and we don't have access to it.What is actually happening?
The server sends a
404
with the second link. The network tab of Chrome (Version 80.0.3987.116 (Official Build) (64-bit)) shows a 404 for the first resource (model-customization.html) but loads other resources request withinmodel-customization.html
, even though caching is disabled in Chrome. It seems that the file is still loaded somehow, together with other required resources (see 1. picture below). What is most surprising is that even the404
page is loaded from our vuepress site with a link to the root path of our site (see 2. picture below). Note that the caching was disabled and previously cached files were deleted. This means that the app is loaded somehow, but it is not possible to hook into the vue-router for case insensitive path matching, which should be enabled by default AFAIK.Other relevant information
npx vuepress info
in my VuePress project: