adobe / acc-js-sdk

A JavaScript SDK for Adobe Campaign Classic
Apache License 2.0
21 stars 22 forks source link

SDK should support abortable requests #61

Open gauravmakkar opened 1 year ago

gauravmakkar commented 1 year ago

Currently there is no way to abort a request from the client. For example:

  1. UI makes requests to fetch the data
  2. While the call is in progress, the UI component unmounts/redirects to some other component.
  3. While un-mounting, the UI should be able to cancel pending HTTP calls to avoid unnecessary attempts to re-render.

Expected Behaviour

Actual Behaviour

Reproduce Scenario (including but not limited to)

Steps to Reproduce

Platform and Version

Sample Code that illustrates the problem

Logs taken while reproducing problem

aimanicose commented 6 months ago

Isn't this scenario covered by AbortController() as described in the doc ?