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 think that there should be a way to add custom backends, because I had to access to many "private" properties while writing the http module for runtime. Maybe a class that provides default, overridable implementations of the methods? Something like:
constcustom=neweshttp.HttpBackend({server: (serverInterface)=>{returnnewSomeServer((socket)=>{socket.on('data',(data)=>serverInterface.ondata(data));socket.on('end',()=>serverInterface.onend());socket.on('close',()=>serverInterface.onclose());socket.on('error',(err)=>serverInterface.onerror(err);});},client: (clientInterface)=>{// ...}});custom.close=(socket)=>socket.someOtherNameForClose();// everything else is left as default
Anyway, it's just a proposal.
The text was updated successfully, but these errors were encountered:
This is another runtime
http
related issue.I think that there should be a way to add custom backends, because I had to access to many "private" properties while writing the
http
module for runtime. Maybe a class that provides default, overridable implementations of the methods? Something like:Anyway, it's just a proposal.
The text was updated successfully, but these errors were encountered: