http-browserify icon indicating copy to clipboard operation
http-browserify copied to clipboard

Support `res.setEncoding` and non-text response types

Open wmrowan opened this issue 12 years ago • 6 comments

Response data in http-browserify seems to default to text. In node http it seems to default to buffer. Independent of defaults, the node version supports setEncoding so you can change the type of the response. The browserify version should do the same.

wmrowan avatar Jul 22 '13 23:07 wmrowan

+1 or support only setEncoding('utf8') and ignore others seems fine.

Jxck avatar Sep 09 '14 09:09 Jxck

See #10

tellnes avatar Sep 09 '14 09:09 tellnes

So, is there a plan to merge the PR?

MiguelCastillo avatar Sep 09 '14 19:09 MiguelCastillo

Would there be any value to throwing or at least logging an error if it is not utf-8?

+1 either way.

jamestalmage avatar Jun 30 '15 04:06 jamestalmage

+1

jstoeffler avatar Apr 17 '16 11:04 jstoeffler

+1 Causes problem on other library. https://github.com/baalexander/node-xmlrpc/issues/135

drawm avatar Sep 23 '16 18:09 drawm