This is a network-wide functionality that has been implemented since 2010 (with some modifications over time):
If you start asking a question, but do not successfully submit, you will see your last saved question draft the next time you visit the ask a question page.
If you start answering a particular question, but do not successfully submit, you will see ...
All posts are saved before posting as a draft once every 45 seconds. You'll notice a draft saved below the post:
Only once the draft is saved, the discard draft option will be made available.
Discard any drafts - you're allowed one per question and answer - to avoid seeing it again when posting.
Reference: Allow questions to be saved as drafts prior to ...