Skip to content

There is performance issue on $.isEmpty #1095

@tasuku-s

Description

@tasuku-s

In my usecase (Angular, many editor, long text in a block), copy, paste and click any line in block that has too long lines makes browser freezing.

I found that isEmpty method in editor.js/src/components/dom.ts has bad algorithm to traverse nodes.

When there are nodes like A, B, C, D, E, then this method traverse nodes as A, B, C, D, E, B, C, D, E, C, D, E, D, E.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions