api

package
v0.0.0-...-521f081 Latest Latest
Warning

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

Go to latest
Published: Oct 29, 2017 License: MIT Imports: 19 Imported by: 0

Documentation

Overview

Package api configures an http server for administration and application resources.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func New

func New() (*chi.Mux, error)

New configures application resources and routes.

func SPAHandler

func SPAHandler(publicDir string) http.HandlerFunc

SPAHandler serves the public Single Page Application.

Types

type Server

type Server struct {
	*http.Server
}

Server provides an http.Server.

func NewServer

func NewServer() (*Server, error)

NewServer creates and configures an APIServer serving all application routes.

func (*Server) Start

func (srv *Server) Start()

Start runs ListenAndServe on the http.Server with graceful shutdown.

Directories

Path Synopsis
Package admin ties together administration resources and handlers.
Package admin ties together administration resources and handlers.
Package app ties together application resources and handlers.
Package app ties together application resources and handlers.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL