Module
Node.Express.Response
- Package
- purescript-express
- Repository
- nkly/purescript-express
#setResponseHeader Source
setResponseHeader :: forall a e. String -> a -> Handler e
Set response header value.
#headersSent Source
headersSent :: forall e. HandlerM (express :: EXPRESS | e) Boolean
Check if headers have been sent already
#setContentType Source
setContentType :: forall e. String -> Handler e
Set Content-Type header.
#setCookie Source
setCookie :: forall e. String -> String -> CookieOptions -> Handler e
Set cookie by its name using specified options (maxAge, path, etc).
#redirectWithStatus Source
redirectWithStatus :: forall e. Int -> String -> Handler e
Redirect to the given URL using custom status.
#setLocation Source
setLocation :: forall e. String -> Handler e
Set Location header.
#sendFileExt Source
sendFileExt :: forall o e. String -> Record o -> (Error -> ExpressM e Unit) -> Handler e
Send file by its path using specified options and error handler. See http://expressjs.com/4x/api.html#res.sendfile