Skip to content

[Meta] [Emotion] Memoize remaining generated styles #10147

Open
11 of 21 issues completed
Open

Description

@weronikaolejniczak

Description

Follow-up to #7561. The checked items there are done. This tracks the components that still call an eui*Styles() generator on render.

Switch those calls to useEuiMemoizedStyles. The style function has to be a static function of the theme. useEuiMemoizedStyles caches by that function, so a generator that also takes padding, size, fill, or a breakpoint needs the dynamic part kept outside the memoized function.

No changelog. This is perf-only.

Out of scope

src/components/filter_group/filter_select_item.tsx still calls euiFilterSelectItemStyles. Do not update that file.

Sub-issues

Sub-issues

11 of 21 Issues completed
Loading 21 sub-issues

Activity

  1. added
    meta
    help wanted
    on Oct 5, 2026
  2. github-actions commented on Oct 5, 2026

    @github-actions

    👋 Thank you for your suggestion or request! While the EUI team agrees that it's valid, it's unlikely that we will prioritize this issue on our roadmap. We'll leave the issue open if you or anyone else in the community wants to implement it by contributing to EUI. If not, this issue will auto close in one year.

  3. 1 remaining item

  4. removed
    help wanted
    on Nov 9, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    emotionmetaperformancetech debt

    Type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions