Expected Behavior:
When a post is autosaved, the cursor should not dislocate
Actual Behavior:
The cursor jumps to the start of the block every time when auto saving
Steps to reproduce :
- Activate CMB2 and use Gutenberg editor to create a post.
- Start wring into a block and wait to it to be auto saved.
- Watch the cursor as it jumps to the start of the block.
What is causing this?
Possibly #1190 introduced this issue. It took me a few hours to debug the issue and finally caught it red handed on cmb2.js#L130 😄. When you comment out that line, there is no such issue.
PS: keep SCRIPT_DEBUG enabled
Debug Info
WP 5.0.2
CMB2 2.5.1