When vue frame mode is in history mode, the sub-routing page refreshes and reports a 405error.

for the project built by vue-cli, the route configuration mode reports a 405error when the history, sub-route page is refreshed, but if the mode mode is changed to hash, the refresh page will display normally, and both modes will display normally if you click Route Jump.

clipboard.png
:

clipboard.png
405:

clipboard.png

, this page is newly built by me, and this has not happened on other people"s pages before, so I think the background configuration should be irrelevant. Is there anything else I need to set up at the front desk?


this can refer to ide/essentials/history-mode.html-sharp" rel=" nofollow noreferrer "> the router document mainly because the front-end route does not really point to a resource, but the js parses and displays the corresponding content, so the resource cannot be found after refresh. You can add configuration under the reference document

.

-Update split line-

jettry reported an error, indicating that this request was sent to the backend java project. What proxy services do your front and rear projects use to allocate traffic? Nginx? Apache? You can refer to the configuration in the documentation and other page routing configurations in the agent to locate the problem here


solution: all sub-routes plus / hello, should not find the corresponding module when refreshing, but the get request error reporting 405 Magi http still doesn't make sense

.
MySQL Query : SELECT * FROM `codeshelper`.`v9_news` WHERE status=99 AND catid='6' ORDER BY rand() LIMIT 5
MySQL Error : Disk full (/tmp/#sql-temptable-64f5-1b38800-2c110.MAI); waiting for someone to free some space... (errno: 28 "No space left on device")
MySQL Errno : 1021
Message : Disk full (/tmp/#sql-temptable-64f5-1b38800-2c110.MAI); waiting for someone to free some space... (errno: 28 "No space left on device")
Need Help?