This repository has been archived by the owner on Dec 15, 2022. It is now read-only.
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.
Description of the Change
Because I've got no response for #106.
Element-cache introduce unfix-able BUG.
And IMO no longer having real perf-gain by this feature now.
I will proceed to send this PR to remove element-cache I believe it should.
I'll explain some history/background for this feature. Pls ignore if you already agree to remove this feature.
Before render-on-visible PR
When #94 and #97 is implemented render-on-visible PR #101 had not yet be merged.
At that time command-palette did
command-pallette
noticeably slow.select-next
/select-previous
always re-render full item.Because of such frequent full-item re-render behavior, element-cache introduced noticeable perf improvement for subsequent launch of
command-palette:toggle
(still very first launch was slow).After render-on-visible PR
At that time command-palette does
command-palette:toggle
launch faster at very first invocation.select-next
/select-previous
just render old and new selected item(two items).Like this, chance of over hundreds full-item rendering is no longer happen.
So perf-gain where element-cache can introduce is no longer noticeable.
Here is Me and @jarle(implemented element-cache)'s discussion about this
#97 (comment)
#97 (comment)
Element cache is not fit in etch's VDOM diff based rendering
Element cache's bad impact was fixed in #105.
But still we can hit BUG introduced by element-cache as I described in #106.
And which is not controllable by command-palette side since it's depend on which pkg/command name to be used by user.
If commands start
a
char, it likely to become top of list, so more chance to hit this BUG.Alternate Designs
I evaluated to keep seem-to-harmless humanized keystroke cache feature.
But I could not say noticeable diff so removed too.
Benefits
No unfixable exception.
Possible Drawbacks
None
Applicable Issues