question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

IndexSizeError in Chrome

See original GitHub issue

steps to reproduce

Using empty editor instance on summernote.org which currently has v0.8.1 of summernote.js

If I do the following: <kbd>a</kbd> -> <kbd>SPACE</kbd> - > <kbd>CTRL</kbd> + <kbd>b</kbd> -> <kbd>SPACE</kbd> (code view shows <p>a <b>&nbsp;</b></p> in Chrome at this point)

I get this error:

Uncaught IndexSizeError: Failed to execute 'setStart' on 'Range': 
The offset 2 is larger than or equal to the node's length (1).

There is a similar error in Microsoft Edge; Firefox is unaffected. I do see that the generated HTML is slightly different in each case.

If I do the following: <kbd>CTRL</kbd> + <kbd>b</kbd> -> <kbd>a</kbd> -> <kbd>a</kbd> -> <kbd>CTRL</kbd> + <kbd>b</kbd> -> <kbd>SPACE</kbd> (code view shows <p><b>aa</b>&nbsp;</p> in Chrome at this point)

I get this error:

Uncaught IndexSizeError: Failed to execute 'setEnd' on 'Range': 
The offset 2 is larger than or equal to the node's length (1).

I see this error only in Chrome.

browser version and os version

Windows 10 Chrome 48

Issue Analytics

  • State:closed
  • Created 8 years ago
  • Reactions:12
  • Comments:18 (5 by maintainers)

github_iconTop GitHub Comments

12reactions
balramkhicharcommented, Mar 24, 2017

Steps to reproduce.

  • Press tab 5-6 times in empty doc
  • Press ctrl+z
screen shot 2017-03-24 at 4 37 41 pm
8reactions
kdonovancommented, Feb 22, 2018

Reproducing @balramkhichar 's instructions from above on the official https://summernote.org/ instance shows the issue isn’t yet fixed (and the removeModule trick from above doesn’t seem to have any impact either).

Read more comments on GitHub >

github_iconTop Results From Across the Web

DrawImage working perfectly in chrome but not in Mozilla ...
Canvas: DrawImage working perfectly in chrome but not in Mozilla [IndexSizeError : Index or size is negative or greater than the allowed amount]....
Read more >
setBaseAndExtent() throws IndexSizeError for too large offsets
setBaseAndExtent() silently clamped too large offset values. IndexSizeError should be thrown for such values to match to Firefox, Edge, ...
Read more >
BUG - Preloader "IndexSizeError" in Firefox, works in Chrome
On Firefox, I get the error "IndexSizeError: Index or size is negative or greater than the allowed amount" and the game crashes on...
Read more >
179627 - IndexSizeError: DOM Exception 1 in page ... - Monorail
Issue 179627: IndexSizeError: DOM Exception 1 in page with devexpress ASPx ... 1. open google chrome ... Chrome version: 25.0.1364.97 Channel: stable
Read more >
IndexSizeError in Chrome on getData() after delete widget
We are migrating CKEditor issue tracking to GitHub. Please, use GitHub to report any new issues. The former tracking system (this website) will...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found