You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
feat: support isr reason for on request error (#68845)
### What
Provide `revalidateReason` in the `errorContext` argument of
`onRequestError` API
#### API
```ts
revalidateReason?: 'on-demand' | 'stale' | undefined
```
### Why
With this property, developer is able to determine if current error is
attached to an ISR request.
* `stale` means it revalidated due to the cache is expired
* `on-demand` means it revalidated due to a user initiated revalidation,
e.g. using `res.revalidate` to revalidate certain path
### Misc
* We don't generate edge entry of instrumentation when there's no edge
routes but instrumentation is presented
Note: for PPR case we'll tackle it later with another PPR specific task,
since we need to provide the render is a postpone render or just normal
render
Closes NDX-23
0 commit comments