Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Sending messages and entering rooms gets very slow if you have a room with a lot of messages #383

Closed
Hugo01 opened this issue Oct 27, 2022 · 1 comment
Labels
bug Something isn't working

Comments

@Hugo01
Copy link

Hugo01 commented Oct 27, 2022

Describe the bug

Hello, first of all, thank you for all the amazing work you did on this library, truly fantastic.
So, this is what happens, everything seems to work fairly well when you have around 100-200 messages loaded
after that you start to feel that sending a message becomes slower after each message, ultil it gets to a point where it takes 7-10 seconds for the message to appear on screen
I have a hunch that this could be the v-for on "room-message" inside the Room.vue component that is probably taking to long to render all these messages

This problem seems much worst when you're on a mobile device

Steps to reproduce

I've created a repo that simulates the problem
https://gitlab.com/hugo6467/vue-advanced-chat-demo
You only need to run:

  • yarn install
  • yarn dev --host (important to use the --host flag to expose the local ip address to your network)
  • grab a phone
  • enter your local ip address on the phone browser, for instance: "http://192.168.25.81:3000/"
  • Click on the "Lots of Messages ROOM"
  • Send a message
@Hugo01 Hugo01 added the bug Something isn't working label Oct 27, 2022
@antoine92190
Copy link
Collaborator

Closing this as it’s a duplicate of #342

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants