I’ve done this so many times but it’s incredibly easy to miss that you have unsaved changes. I feel like this could be made into a much more noticeable popup.
Thanks for taking the time to provide feedback. We have a dedicated feedback site for feature requests at https://feedback.render.com/features.
However, I’ll pass this one on to the team.