Overview
Saving drafts can prevent data loss when users close a form accidentally, lose network connection, or step away for too long before final submission. Momen offers two main ways to implement this: manual saving triggered by a button click, and automatic saving triggered when an input field loses focus.
Method Comparison
| Dimension | Method 1: Manual Draft Saving | Method 2: Real-time Draft Saving |
|---|---|---|
| Interaction Core | User clicks a “Save Draft” button to store progress | Data updates automatically when input fields lose focus |
| Trigger Timing | Explicit, user-controlled | Implicit, automatic |
| Implementation Logic | Page variable (form_id) toggles between create and edit modes | Pre-retrieve a blank placeholder record, then update on blur events |
| Resource Consumption | Low — only makes requests when the user clicks save | Auto-saving triggers more frequent database updates, which may increase server load. Use it where user experience outweighs resource cost. |
| Use Cases | Short forms, or cases where users prefer explicit confirmation | Long-form editing, multi-step workflows, high-value inputs |
Solution Details
Click the cards below to view the step‑by‑step tutorial for each method:
How to Choose?
- Choose Manual Draft Saving if your form is short or users prefer to decide explicitly when to save. This method uses fewer resources and has simpler logic.
- Choose Real-time Draft Saving if your application involves long-form input or multi-step processes such as approvals. Automated saving provides a safety net for users and prevents data loss without requiring extra clicks.
Last updated on