Vue value transfer problem

recently learned vue, to practice passing values between components.
this.$router.push ({name: "detail", params: {userInfo: thisName}})
accept: this.msg = this.$route.params.userInfo;
but why does this value become undefined, after the page refreshes?

Mar.05,2021

should be this.$route.params.params.userInfo, and this is not a value transfer between components.


it seems that this is not a value transfer, right?


where does the routing value come from when the refresh page overloads?
this question can be figured out in a moment

.

routing value

paramsquery
queryget
paramspost  query url,
,

change params to query

pass a value: this.$router.push ({name: 'detail', query: {userInfo: thisName}})
accept: this.msg = this.$route.query.userInfo;


your method is to route jump transfer parameters
and then route to configure
is there any /: userInfo

after your routing address?
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-1e3c53d-446ac.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-1e3c53d-446ac.MAI); waiting for someone to free some space... (errno: 28 "No space left on device")
Need Help?