-
Notifications
You must be signed in to change notification settings - Fork 1.8k
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
Refactor feed slices #4834
Merged
Merged
Refactor feed slices #4834
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Mergefeed logic relies on that.
Your Render PR Server URL is https://social-app-pr-4834.onrender.com. Follow its progress at https://dashboard.render.com/web/srv-cqhbg908fa8c739rvkjg. |
11 tasks
|
haileyok
approved these changes
Jul 25, 2024
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Did some testing, toggled the various settings and things seem to line up localhost vs. bsky.app.
estrattonbailey
added a commit
that referenced
this pull request
Jul 31, 2024
* origin/main: (30 commits) Only show "followed you back" when appropriate (#4849) [Web] Retrigger onEndReached if needed when content height changes (#4859) Remove unused NoopFeedTuner (#4856) useDedupe callback (#4855) [Video] Uploads (#4754) Make label required in link components (#4844) Boolean filter improvement alternative: TS upgrade (#4840) Add label to profile card (#4843) Improve a11y on noty feed (#4842) Add labels in feed card (#4836) Add labels to mod details dialog (#4839) Add labels to a few missing places (#4838) Add labels in list card (#4837) Refactor feed slices (#4834) `true` (#4833) Replace `import hairlineWidth =` with const (#4831) [Videos] Video player - PR #1 - basic player (#4731) Bump 1.90 (#4832) Fix sloppy filter(Boolean) types (#4830) Fuggedaboudit (#4829) ...
estrattonbailey
added a commit
that referenced
this pull request
Jul 31, 2024
* origin/main: (37 commits) Only show "followed you back" when appropriate (#4849) [Web] Retrigger onEndReached if needed when content height changes (#4859) Remove unused NoopFeedTuner (#4856) useDedupe callback (#4855) [Video] Uploads (#4754) Make label required in link components (#4844) Boolean filter improvement alternative: TS upgrade (#4840) Add label to profile card (#4843) Improve a11y on noty feed (#4842) Add labels in feed card (#4836) Add labels to mod details dialog (#4839) Add labels to a few missing places (#4838) Add labels in list card (#4837) Refactor feed slices (#4834) `true` (#4833) Replace `import hairlineWidth =` with const (#4831) [Videos] Video player - PR #1 - basic player (#4731) Bump 1.90 (#4832) Fix sloppy filter(Boolean) types (#4830) Fuggedaboudit (#4829) ...
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
I'm refactoring feed slicing. This refactor should fully preserve the existing behavior but it makes strategic code changes that will prepare us for the next PR #4835, which solves longstanding problems with how replies show up in the feed.
The best way to follow along, unfortunately, is to read commit-by-commit. Each change is meant to be atomic and safe (mostly manipulation). The main theme of this refactor is to decouple the shape of a "slice item" from
FeedPostView
so that #4835 can construct it on-the-fly from parent and root with correct information. I'm tucking away low-level access ofslices[i].items.reply
and similar fields into theslice
API itself so that I can later change the type of individual items.I guess you could also just read the entire diff.
By the end of this refactor, the only code that reaches out into "internals" of a slice is the slice item manipulation logic which the next PR will get rid of.
Test Plan
This is going to require some non-trivial testing. Things you'll want to look at:
The goal in this PR is to stay aligned with the behavior on main.