Wysiwyg-editor: JS error when using backspace in a list

Created on 18 Jul 2019  路  3Comments  路  Source: froala/wysiwyg-editor

Expected behavior.

When writing text in a list it should be possible to use backspace without JS errors.

Actual behavior.

When pressing the backspace key in a list (ordered or unordered) a JS error occurs:
Failed to execute 'matches' on 'Element': 'li:first' is not a valid selector.

Steps to reproduce the problem.
Editor version.

3.0.3

OS.

Windows 10

Browser.

Chrome 75.0.3770.142

bug version 3

Most helpful comment

We have an application experiencing this also, Have seen 3,415 instances of this error in the last 8 days. Will a fix for this be coming soon as it's creating a lot of noise in our logs.

All 3 comments

I got same problem, too.
I thought the reason is li:first is the valid selector to jQuery but not native js matches method.
And froala team are doing replace jQuery with native js but miss the selector handling.

We find that when this error occurs the onChange callback isn't called. Meaning our model and editor contents get out of sync. We've had to make changes to our code to work around the fact that Froala will drift out of sync when people are making quick edits to bullet point lists.

We have an application experiencing this also, Have seen 3,415 instances of this error in the last 8 days. Will a fix for this be coming soon as it's creating a lot of noise in our logs.

Was this page helpful?
0 / 5 - 0 ratings

Related issues

cksachdev picture cksachdev  路  4Comments

Nucs picture Nucs  路  4Comments

george-norris-salesforce picture george-norris-salesforce  路  4Comments

DerekJDev picture DerekJDev  路  3Comments

jmsche picture jmsche  路  3Comments