http

package
Version: v0.0.0-...-e34a5cd Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Oct 31, 2016 License: BSD-2-Clause Imports: 8 Imported by: 0

Documentation

Rendered for js/wasm

Index

Constants

This section is empty.

Variables

View Source
var DefaultTransport = func() RoundTripper {
	switch {
	case js.Global.Get("fetch") != js.Undefined && js.Global.Get("ReadableStream") != js.Undefined:
		return &fetchTransport{}
	case js.Global.Get("XMLHttpRequest") != js.Undefined:
		return &XHRTransport{}
	default:
		return noTransport{}
	}
}()

Functions

This section is empty.

Types

type XHRTransport

type XHRTransport struct {
	// contains filtered or unexported fields
}

func (*XHRTransport) CancelRequest

func (t *XHRTransport) CancelRequest(req *Request)

func (*XHRTransport) RoundTrip

func (t *XHRTransport) RoundTrip(req *Request) (*Response, error)

Source Files

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
t or T : Toggle theme light dark auto
y or Y : Canonical URL