[Lens] Suggestion performance#43875
Conversation
of Joe's work
Fix auto scaling edge cases
scale both the number and the label.
Use format hints and field formatters in metric vis
…erybar-integration
… not suggestion generation
💚 Build Succeeded |
💔 Build Failed |
💚 Build Succeeded |
|
@chrisdavies @wylieconlon I do not intend to merge this PR as is (note the draft status), but this PR shown an approach to keep the suggestions from re-rendering until something actually changed. The actual preview renderer is memoized, making it necessary for the expression string to change for re-rendering. To show new suggestions as early as possible, only the preview component is debounced, not the suggestion list itself. To keep the expression string stable across multiple state changes, Maybe you have a better idea how to tackle this. |
💚 Build Succeeded |
|
After syncing with @chrisdavies most of these problems will disappear if we expose an |
|
Pinging @elastic/kibana-app |
|
@chrisdavies Do you plan to refactor the usage of state setting before feature freeze to make this possible or should we find an interim solution? |
|
Closing this as it will get addressed later |
Based on #43688 and #43865
Improves the performance of suggestions by not re-running the expression if it didn't change. Also debounces the preview instead of the suggestion to show the user other options as fast as possible.
We could add a fallback to the icon as long as the expression loading hasn't finished here.