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
As you can see, content of the body is printed only when curl is used with --no-buffer parameter.
I can't find xh option equivalent with curl --no-buffer from documentation or source code.
Any help would be appriciated!
The text was updated successfully, but these errors were encountered:
This happens because --stream only shows complete lines, like HTTPie. See httpie/cli#1060
We don't have an option like --no-buffer. Maybe we should.
I see two workarounds:
Send a newline immediately after <div id="root"><!--$?--><template id="B:0"></template>suspending...<!--/$-->. Then curl won't need --no-buffer either.
Pipe the output through cat: xh :3000 --stream --print=hb | cat
This disables the "smart" line-buffering and just sends everything through as soon as it's received.
(--print=hb ensures you still see the headers, those are hidden by default when piping.)
I'm testing streaming SSR react server with
xh
, and I found thatxh
does not display entire response unlike whatcurl
does.Testing against same endpoint with
xh
andcurl
:As you can see, content of the body is printed only when
curl
is used with--no-buffer
parameter.I can't find
xh
option equivalent withcurl --no-buffer
from documentation or source code.Any help would be appriciated!
The text was updated successfully, but these errors were encountered: