(response)
| 42 | } |
| 43 | |
| 44 | function refresh(response) { |
| 45 | startTransition(() => { |
| 46 | const nextCache = new Map(); |
| 47 | if (response != null) { |
| 48 | const locationKey = response.headers.get('X-Location'); |
| 49 | const nextLocation = JSON.parse(locationKey); |
| 50 | const nextContent = createFromReadableStream(response.body); |
| 51 | nextCache.set(locationKey, nextContent); |
| 52 | navigate(nextLocation); |
| 53 | } |
| 54 | setCache(nextCache); |
| 55 | }) |
| 56 | } |
| 57 | |
| 58 | function navigate(nextLocation) { |
| 59 | startTransition(() => { |
no test coverage detected