Vue opens a new tag, how to transfer an object from new to a new page

const mqClient = Stomp.Stomp.client("ws://192.168.1.186:10676/ws");

I want to pass the mqClient object to the newly opened interface

<router-link tag="a" target="_blank"  :to=""/singleMonit/"+ singleId">
      <span></span>
</router-link>

can vue achieve this function (mqClient is rmq persistent connection class websocket)

Jan.17,2022

if the new route is opened after receiving the object, you can use js to control the route jump
this.$router.push ({path: / singleMonit/$ {singleId} , query: {key:value}})
if there is no association between the acquisition and the jump, you can use vuex

.
Menu