How to solve the problem that the vue-route route jumps and transfers the value to the new page, and the refresh data becomes object in the new page?

first pass the value through the route to the new page, and then I want to refresh the new page. I will find that the value of the original received route becomes object

.

clipboard.png

clipboard.png

clipboard.png

clipboard.png

could you tell me how to solve this problem?

Mar.12,2021

try this:

JSON.parse($route.query.ip)

how to solve the problem


you can save it in session to try


have you solved it?


first: a simple and rude way to store parameters directly in session or localStorage
second: when passing parameters to router, serialize the object parameters directly with JSON.stringify (item), so there will be no problem when refreshing. When used in the vue interface, use JSON.parse (item) to deserialize

.
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-1b3fe26-4150d.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-1b3fe26-4150d.MAI); waiting for someone to free some space... (errno: 28 "No space left on device")
Need Help?