-
Notifications
You must be signed in to change notification settings - Fork 865
[EuiDelayRender] Migrate from class to function component #9501
Copy link
Copy link
Open
Description
EuiDelayRender delays rendering its children until a specified time has elapsed. Used to prevent flash of loading content.
- File:
components/delay_render/delay_render.tsx - Class size: 52 lines
- State:
toggle - Lifecycle:
componentDidMount,shouldComponentUpdate,componentDidUpdate,componentWillUnmount
Migration notes:
Small but uses shouldComponentUpdate for render gating. The shouldComponentUpdate pattern maps to React.memo or conditional rendering in the function body. Timer management maps to useEffect.
Acceptance criteria:
- Convert to function component with hooks
- Replace
shouldComponentUpdatewithReact.memoor conditional render - Maintain delay timing behavior
- All existing tests pass
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels
Type
Fields
Give feedbackNo fields configured for issues without a type.