Closed tyleretters closed 11 months ago
i just tried to reproduce this behavior and i can't get it to happen in either a release build or a debug build.
what browser / os are you using?
brave / macos big sur.
forgot to add that you need to click in the file:
okay, i think i might have an idea as to what is going on. when switching files the editor itself is not getting torn down and recreated but the contents of the editors copy of the buffer is being changed. i suspected the editor (which is ace
) is treating the change as if it is one continuous set of edits.
hopefully there is a way to at least truncate the undo stack. a longer term fix might be to create one instance of the editor per file...
it feels like the simplest solution would be to reinstantiate the editor for each file? i wonder if there are other side effects besides the undo stack...
Plain english: you can undo into previous files.
To reproduce:
ack/README.md
.ack/lib/ack.lua
.ack/lib/ack.lua
is filled with the contents ofREADME.md
.