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
I'm confused about how interceptors are intended to work, which means I'm very likely doing something wrong.
I have inferred from the response interceptor example that they may be used to transform the body of a response. However, I find the example misleading because short-circuiting the reduction as described results in the handler receiving something that doesn't look like a response. And if I don't want the short-circuit the response interceptor pipeline, it isn't clear to me how to generate an AjaxResponse with the new transformed body that I want to have propagate through the remaining interceptors...
As a quick hack to handle a similar situation to the one described in #76, I've had to resort to this:
I'd be pretty amazed if you could use interceptors to get around my lack of support for streaming, but it would be absolutely awesome if you could. However, I think that what you want is to use is a response format. (Response formats are actually interceptors, but with a lot of code written for you.)
I'm confused about how interceptors are intended to work, which means I'm very likely doing something wrong.
I have inferred from the response interceptor example that they may be used to transform the body of a response. However, I find the example misleading because short-circuiting the reduction as described results in the handler receiving something that doesn't look like a response. And if I don't want the short-circuit the response interceptor pipeline, it isn't clear to me how to generate an
AjaxResponse
with the new transformed body that I want to have propagate through the remaining interceptors...As a quick hack to handle a similar situation to the one described in #76, I've had to resort to this:
but I feel like missing something blindingly obvious.
The text was updated successfully, but these errors were encountered: