Module res

Module res 

Source
Expand description

HTTP response and its constructors

Structs§

HttpResponse
Your response

Functions§

bytes
Response of bytes (application/octet-stream)
file
Responds with a file
html
HTML response (text/html)
json
JSON response (application/json)
redirect
HTTP redirect with the Location header
sse
text
Plaintext response (text/plain)