Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func JSON ¶
func JSON(w http.ResponseWriter, data interface{})
func JSONError ¶
func JSONError(w http.ResponseWriter, err error)
JSONError JSON serializes the given struct as JSON into the response body. It also sets the Content-Type as "application/json".
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.