Skip to content
This repository was archived by the owner on Sep 27, 2024. It is now read-only.
This repository was archived by the owner on Sep 27, 2024. It is now read-only.

Expensive HTML parser setup runs on each key press in Android #887

@jonnyandrew

Description

@jonnyandrew

Problem

On Android, an expensive HTML parser setup operation runs on each key press. This contributes to slow/laggy typing experience which is particularly visible in debug builds.

Proposed solution

Currently, each time the composer model changes, the Android platform code creates a new instance of HtmlToSpansParser which in turn creates a new instance of Parser. This newly initialised Parser then runs an expensive setup operation because it has not parsed any content before.

Improve the efficiency of the editor by holding a reference to some of these objects and reusing them.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions