I am looking to add a live stream chat function to one of our sites. It’s easy to make it so the most recent messages show up at the top and you’re always caught up that way, but I want to mirror the look of most (all?) messaging/chat systems where new messages show up at the bottom, and the person is always scrolled to the bottom by default.
I have done “scroll to last item” on page load before for similar but less dynamic situations, but that doesn’t work well for things that will be constantly updating. I could also do “scroll to last item” any time a new item is created which would probably work nice most of the time, but then if someone tries to scroll back while others are sending messages they’ll keep getting bumped to the bottom.
Any ideas? Seems like it should be something that has been done before.