Empresas
Empregos
  • Sobre nós
  • Soluções
    • Publicação de vagas
      Publique sua vaga e receba candidatos qualificados em 48h.
    • Avaliações de candidatos
      Mais de 500 testes técnicos e psicológicos, mais anti-fraude.
    • Headhunting
      Busca executiva personalizada do início ao fim.
    • Folha de Pagamento + EOR
      Dispersão de folha e EOR em mais de 15 países da LATAM.
  • Preços
  • Empregos

0

301
Visualizações
Laravel echo server console says left the channel and again joins the channel while navigating through pages?

I am trying to add realtime functionality to my laravel app which is being developed in laravel-5.4. So, I have implemented a simple chat example from the documentation that is laravel-echo-server with redis and socket.io. It’s working fine but I have noticed a weird behaviour that is when the user navigates to different pages across the application, the laravel-echo-server console says left the channel and again joined the channel so is it intended behaviour and what is the best practise to use it. am i doing something wrong here? I don't want him to left the channel, instead I want to stay him at the same connection.

over 4 years ago · Santiago Trujillo
1 Respostas
Responde à pergunta

0

If you change page, everything is lost and a new content is dowloaded from the server. So it's normal that the user "left the channel" then re"joined the channel". It's the intended behavior.

If you don't want this kind of behavior, you have to stay one the same page (so implementing something like a single page application). Because when you leave a page to go to another, current scripts stops then a new world is re-created.

over 4 years ago · Santiago Trujillo Relatório
Responde à pergunta
Encontrar trabalhos remotos

Descubra a nova forma de encontrar um emprego!

melhores empregos
Principais categorias de trabalho
Empresas
Postar vaga Preços Comercial
Jurídico
Termos e Condições Política de privacidade
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Recomende algumas ofertas para mim
Preciso de ajuda