Breaking
Response
methodstatus
renamed toset_status
(this is to allow havingstatus
as a field).
Changes
- Improve rendering of templates.
No longer force render data as JSON if using an HTML template. - Allow nested partials, their path must be relative.
- Added
jobj
function to serialise objects to JSON inrender
. - Allow passing
host
andport
tostart()
method. - Added
host
andport
active bindings. - Move internal
is_running
field to private. - Added
status
active binding onResponse
. - Added
get_header
,set_header
, andset_headers
toResponse
. - Allow adding multiple cookies to the request.
- Add
parseCookie
JavaScript helper function to JavaScript file. - Allow customising the cookie parser with
as_cookie_parser
. - Allow adding cookie value preprocessors with
as_cookie_preprocessor
. - Arguments to
cookie
method onResponse
take options. - Added
clear_cookie
method toResponse
- Cookies of the same name overwrite rather than duplicate.
- Added
content_*
family of convenience function to set content type headers. - Export
serialise
- Fixed issue where wrong path pattern was matched.
- Catch error if no route is specified.
- Do not force body to character fixes #44
- Do no force content type on response fixes #45
- Deprecate passing headers to
response
orsend
-like functions, use
header
method. - Deprecate
set_header
in favour ofheader
method. - Added family of
header_content*
methods to easily setContent-Type
. - Request
HEADERS
is always alist
. - Deprecate
set
andget
on Response and Request, this is no longer
needed the environments are no longer locked;res$myVar <- 2L
. - Deprecate
status
argument of responses, the active binding should
be used instead;res$status <- 404L
. - Partially improved route matching.
- Allow customising the path to pattern converter.
- Added
get_header
method to the retrieve a specific method. - Fix htmlwidget response.
- Added
image
,png
andjpeg
methods toResponse
to serve images. - Added
ggplot2
method toResponse
. - Allow
use
method onRouter
these will only be applied to paths
of said router. - Added
parse_*
methods to theRequest
. - Cookie
path
defaults to/
. - Fix default serialiser
- More robust
parser_*
methods and fuctions. - Empty cookie is empty list instead of empty string.
- Added
mockRequest
to for testing purposes. - Fixed
port
,host
, andwebsocket
active bindings. - Add ability to create custom renderer, see
jader, and
pugger.