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.

Parse & Format example loses caret position

See original GitHub issue

URL for the parse & format example: https://codesandbox.io/s/10rzowm323

Bug reproduction ( ^ means caret)

(123) 12^3-1234  
// backspace, then 1
(123) 131-2341^

Note that this works:

(123) 123-12^34 
// backspace then 1
(123) 123-11^34

env: Windows 10, Firefox 60

Is this a bug in final-form or a bug in the example?

I used to solve this using cleaveJS, but I’m hoping for some other lighter alternative…

Issue Analytics

  • State:closed
  • Created 5 years ago
  • Comments:9 (1 by maintainers)

github_iconTop GitHub Comments

8reactions
karolis-shcommented, Oct 4, 2018

I can still reproduce this in the codesandbox 😕

1reaction
erikrascommented, May 21, 2018

Fixed. Thanks!

Read more comments on GitHub >

github_iconTop Results From Across the Web

Rangy loses caret position on backspace in contenteditable div
calling a function that every time the user types something, it parses the content and formats specific tokens.
Read more >
Finding Cursor Position in Rich Text - Forums - IBM Support
I am using the "getCursorPosition" function to see where to insert the text. However, this method falls apart when there is rich text...
Read more >
How to parse tmpro text that contains formatting tags and ...
Hi, I'm trying to remove the first line from the start of a tmpro text element which may contain formatting tags, but I'm...
Read more >
Scintilla Documentation
A simple sample using Scintilla from C++ on Windows. ... The caret exists between character positions and can be located from before the ......
Read more >
Safari Technology Preview Release Notes - Apple Developer
Stopped parsing context-sensitive colors in override-color (r283537). Updated the implementation of the CSS Font Loading API to be closer to the spec and...
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