-
Notifications
You must be signed in to change notification settings - Fork 2k
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
Update comment counts #40854
Update comment counts #40854
Conversation
We need a way to query what is onscreen in a Reader full post view if a user hits a reader link directly. The use case is joining related channel(s) after the websocket connects.
To come in follow up PR
Here is how your PR affects size of JS and CSS bundles shipped to the user's browser: Webpack Runtime (~661 bytes removed 📉 [gzipped])
Webpack runtime for loading modules. It is included in the HTML page as an inline script. Is downloaded and parsed every time the app is loaded. App Entrypoints (~34359 bytes added 📈 [gzipped])
Common code that is always downloaded and parsed every time the app is loaded, no matter which route is used. Sections (~167784 bytes removed 📉 [gzipped])
Sections contain code specific for a given set of routes. Is downloaded and parsed only when a particular route is navigated to. Async-loaded Components (~122180 bytes removed 📉 [gzipped])
React components that are loaded lazily, when a certain part of UI is displayed for the first time. Legend What is parsed and gzip size?Parsed Size: Uncompressed size of the JS and CSS files. This much code needs to be parsed and stored in memory. Generated by performance advisor bot at iscalypsofastyet.com. |
What about bumping the count in the post instead of making a separate pathway ( Something like this (not fully tested -- there's a bit of odd what I presume to be placeholder driven flutter in the window posting):
|
Woof, the "flake" is the flutter between the tl;dr: we need to extract the fancy logic that gives (on the bright side....we'd be fixing this as |
This is still work in progress, at first I thought I can just increment totals but as it turns out on hard refreshes it won't work so I added the global_ID on the backend to make it work, I guess updating the inline reader post would make more sense now that we have the global id, I'll have to take a look comments and comments/counts is just so much fun when combined with reader's posts. |
I'm not quite sure I can reproduce the flakiness you mentioned, could you provide a quick video recording if possible. I pushed some updates that would contain the comments count to the reader concern. |
c61a6d3
to
3951dc2
Compare
Closed in favor of using lasagna.js |
Built on top of #40720
Changes proposed in this Pull Request
Update realtime comment counts
Testing instructions
Example https://d.pr/v/euB0QQ