Adding X-Turbo-Request-Id support · Issue #73 · rails/request.js (original) (raw)
Turbo requests now keep track of a set of the last 20 or so requests and submits an ID for each turbo request to the server so that if a response is broadcast back to browsers the initiating browser can ignore the page reload update:
https://github.com/hotwired/turbo/blob/main/src/http/fetch.js
It would be useful to hook into this functionality in request.js
. Would you be open to that?
Hopefully it's a case of just optionally importing the augmented fetch
from the above file? I'm sure it could be complicated though :D