Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func NewDevServer ¶ added in v0.10.14
func NewDevServer(packageDir PackageDir, devPort model.WebDevPort) (*devServer, error)
func NewFakeServer ¶
func NewFakeServer() fakeServer
func StripPrefix ¶ added in v0.10.16
func StripPrefix(prefix string, h http.Handler) http.Handler
Middleware that attaches a server at a subpath. Modeled after http.StripPrefix, but attaches the work it did to the Request Context.
Types ¶
type PackageDir ¶ added in v0.10.14
type PackageDir string
The directory where the package.json where our JS source code lives.
type PublicPathPrefixContextKey ¶ added in v0.10.16
type PublicPathPrefixContextKey struct{}
type Server ¶
type Server interface {
http.Handler
Serve(ctx context.Context) error
TearDown(ctx context.Context)
}
func GetEmbeddedServer ¶ added in v0.26.3
func GetEmbeddedServer() (Server, bool)
Click to show internal directories.
Click to hide internal directories.