The Web Ratings
Going Deeper

Offline Support

Local fallback and resilient UX

Behavior

When network/API errors occur during submission:

  • The review is validated locally
  • Data is enriched (timestamps, source, original error)
  • Stored locally via an internal cache (storeFeedbackLocally)
  • User still sees the success screen (no error event is emitted) so the experience stays positive

Important: The widget does not automatically retry stored submissions when the connection is restored. Failed submissions are saved to localStorage for potential future handling, but there is no built-in reconnection listener or automatic sync.

What Gets Stored

  • Redacted review metadata (not full text in events)
  • Rating, user email/name, timing info, error context
  • Up to 10 recent failed submissions

Recommendations

  • Listen to rating:submitted to confirm when a submission actually reached the server
  • The widget does not emit a separate error event when it falls back to local storage
  • Keep the script up-to-date to benefit from retry/backoff improvements during the initial submission attempt