Description
There are two issues on the checkout page that need to be addressed:
1. Newly Added Address Does Not Appear Instantly
When a user adds a new address from the checkout page using the "Add New Address" drawer:
- The address is successfully saved to the database.
- The drawer closes successfully.
- However, the newly added address does not appear in the checkout address list immediately.
- The user must manually refresh the page before the new address becomes visible.
Expected Behavior
- After saving an address, the checkout page should update automatically.
- The newly created address should appear instantly in the address selection list without requiring a page refresh.
2. Cart Is Lost After Page Refresh
When the user refreshes the checkout page:
- The cart state is cleared.
- Checkout becomes empty.
- User must return to the restaurant page and add items again.
Expected Behavior
- Cart contents should persist across page refreshes.
- Refreshing the checkout page should not remove cart items.
- Cart state should be restored automatically from persistent storage (localStorage, database, or another persistence layer).
Priority
Medium
Affected Areas
- Checkout Page
- Address Drawer
- Auth/User State Synchronization
- Cart State Persistence
Notes
Current workaround for the address issue is manually refreshing the page. No workaround exists for the cart reset issue.
Description
There are two issues on the checkout page that need to be addressed:
1. Newly Added Address Does Not Appear Instantly
When a user adds a new address from the checkout page using the "Add New Address" drawer:
Expected Behavior
2. Cart Is Lost After Page Refresh
When the user refreshes the checkout page:
Expected Behavior
Priority
Medium
Affected Areas
Notes
Current workaround for the address issue is manually refreshing the page. No workaround exists for the cart reset issue.