Documentation ¶
Index ¶
- func IEC64(bytes int64) string
- type WebServer
- func (ws WebServer) ServeAssets() func(w http.ResponseWriter, r *http.Request)
- func (ws WebServer) ServeDir(contentType string) func(w http.ResponseWriter, r *http.Request)
- func (ws WebServer) ServeFile(urlPath, contentType string) func(w http.ResponseWriter, r *http.Request)
- func (ws WebServer) ServeImages() func(w http.ResponseWriter, r *http.Request)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type WebServer ¶
func (WebServer) ServeAssets ¶ added in v0.11.1
func (ws WebServer) ServeAssets() func(w http.ResponseWriter, r *http.Request)
ServeAssets detects the Content-Type depending on the asset extension.
func (WebServer) ServeFile ¶
func (ws WebServer) ServeFile(urlPath, contentType string) func(w http.ResponseWriter, r *http.Request)
ServeFile handles one specific file (and its specific Content-Type).
func (WebServer) ServeImages ¶
func (ws WebServer) ServeImages() func(w http.ResponseWriter, r *http.Request)
ServeImages detects the Content-Type depending on the image extension.
Click to show internal directories.
Click to hide internal directories.