mirror of
https://github.com/GSA/notifications-admin.git
synced 2026-02-06 19:34:15 -05:00
At the moment the first AJAX call is triggered as soon as the page loads. We then look at its response time to work out how long to wait until making the next call. This isn’t great because: - stuff is unlikely to have changed straight away, so it’s a waste of a call - while the DOM is being updated it seems to introduce a delay in clicks on links, which is either more pronounced or more noticeable when it’s happening straight away, making the UI feel less snappy I chose a value of 2 seconds as a rough proxy for the minimum time we’d expect to see a notification go from created to delivered. Median time-to-delivered was 2.9 seconds when we analysed it for https://github.com/alphagov/notifications-admin/pull/2974#discussion_r286101286