Skip to content
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

feat: add getters for history util values #11

Merged
merged 4 commits into from
Mar 12, 2024
Merged

Conversation

lwhiteley
Copy link
Collaborator

@lwhiteley lwhiteley commented Mar 11, 2024

canUndo, canRedo and getCurrentChangeDate do not cause a component to re-render when used by themselves.

To resolve this, equivalent getters are exposed to directly access the intended values

closes #10

@lwhiteley lwhiteley requested a review from dai-shi March 11, 2024 15:18
Copy link
Member

@dai-shi dai-shi left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The code looks okay with this. I didn't expect the use case of object getters and ref. It's nice to know.

Maybe we should prefer using this to proxyObject in all the places in the library code. (My original idea was to avoid this completely.)

@lwhiteley
Copy link
Collaborator Author

Maybe we should prefer using this to proxyObject in all the places in the library code. (My original idea was to avoid this completely.)

K will check in another changeset

@lwhiteley lwhiteley merged commit d5b7a92 into main Mar 12, 2024
1 check passed
@lwhiteley lwhiteley deleted the add-getter-alternatives branch March 12, 2024 05:41
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

No rerender by value or history change
2 participants