Join GitHub today
Prompt to save when unloading if editor is in conflict #15798
Normally we don't prompt to save editors when reloading or closing a window. But if an editor's contents have changed on disk, then we would need to save the editor to avoid data loss.
I'm not positive that this is the best solution, but it seems reasonable to let you know that if you don't save, you'll lose your changes. Ultimately, we need a little more UI to surface the fact that the editor has changed on disk.