Add the ability to navigate to posts within a thread
This commit is contained in:
@@ -78,6 +78,9 @@ export const PostThread = observer(function PostThread({
|
||||
function* flattenThread(
|
||||
post: PostThreadViewPostModel,
|
||||
): Generator<PostThreadViewPostModel, void> {
|
||||
if (post.parent) {
|
||||
yield* flattenThread(post.parent)
|
||||
}
|
||||
yield post
|
||||
if (post.replies?.length) {
|
||||
for (const reply of post.replies) {
|
||||
|
||||
Reference in New Issue
Block a user