Skip to content

Continuous style recalculations and high CPU usage in Safari #1322

@wannevancamp

Description

@wannevancamp

Description

In Safari-based browsers, loading algolia/autocomplete causes severe performance and rendering issues. Layout styles are continuously invalidated and recalculated, the CPU stays overloaded, and the rendering queue is permanently full. This delays user interactions and makes the page visibly slower. Pages without algolia/autocomplete do not experience these CPU-intensive rendering problems.

Reproduction

Steps

  1. Open Safari browser
  2. Go to a webpage where algolia/autocomplete is active ex. https://www.algolia.com/doc/ui-libraries/autocomplete/introduction/getting-started/
  3. Open the developer tools > Timelines
  4. Click the red dot to record a session
  5. You will see a high CPU load and continuous rendering of the layout.
screencast.2025-08-26.22-11-29.mp4

Expected behavior

In browsers like Chrome or Firefox, this continuous rendering and high CPU usage does not occur. In Safari, however, it causes visible DOM rendering delays, which are especially noticeable on older devices or pages with many DOM elements.

Environment

  • OS: Tested on macOS, though other operating systems may be affected as well
  • Browser: Safari
  • Autocomplete version: v1.19.2

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions