I simply created a connection by
const client = new Stomp(config) ;client.connect(function(sessionId, err));and tried to pass it as parameter to a manager
for instance : const myManager = new MyManager(client);
And use it into myManager :
function MyManager(client){
client.subscribe();
}
But I got the error "Not connected" on MyManager side.
Hey guys, I posted my issue there https://stackoverflow.com/questions/49303927/create-a-singleton-of-stomp-client-and-pass-it-as-parameter If someone got a solution, feel free to answer me please.
I simply created a connection by
const client = new Stomp(config) ;
client.connect(function(sessionId, err));
and tried to pass it as parameter to a manager for instance :const myManager = new MyManager(client);
And use it into myManager :But I got the error "Not connected" on MyManager side.
What I did wrong ?