I'd like to be able to preserve the state of the comments page between reloads. I collapse the threads that I don't want to see anymore.
I have implemented a basic persistent collapsed state. Should anyone be interested, I will push to my fork for review. There are some design considerations that arise:
What is the expiration policy of the state objects in localstorage?
How is one notified of new comments within collapsed threads? I support extending the existing CommentTracker to add an indicator on the topmost visible parent. (I think this is a generally useful design enhancement even outside of the collapsible feature.)
During the implementation, it turned out to be easier to have an abstract model of the thread. I build a comment graph during init() and use that to drive the UI changes. This is likely to be useful for implementing other comment-related features.
I'd like to be able to preserve the state of the comments page between reloads. I collapse the threads that I don't want to see anymore.
I have implemented a basic persistent collapsed state. Should anyone be interested, I will push to my fork for review. There are some design considerations that arise:
During the implementation, it turned out to be easier to have an abstract model of the thread. I build a comment graph during init() and use that to drive the UI changes. This is likely to be useful for implementing other comment-related features.