bogart.middleware.session
assumed thatreq.env
would be unique per request; however, it is not. Corrected issues caused by this.
bogart.middleware.bodyAdapter
now adapts responses that are of type Buffer or Stream to JSGI responses.- Fixed a bug in
bogart.middleware.bodyAdatper
where Stream returns were not being handled properly. - Added
bogart.config
. The default environment is 'development' and may be overridden with the BOGART_ENV environment variable. - Expose
DefaultIdProvider
andDefaultDataProvider
as properties ofbogart.middleware.session
.
- No longer reject a return that does not include all properties of a valid JSGI response. This change facilitates Bogart as a middleware platform.
- Added
bogart.middleware.batteries
, a batteries included JSGI stack for rapid application development. - The deprecated
bogart.app
has been reclaimed for the purpose of creating application stacks more easily than chaining JSGI middleware manually or usingbogart.build
. bogart.build
is deprecated.- Added
bogart.q
which exposes the promise implementation used by Bogart. - Added
bogart.promisify
which adapts node-style asynchronous functions to promises. - Added
bogart.proxy
, a helper to create a JSGI response that proxies a URL. - Added
viewEngine.share
, a helper for serializing JavaScript to views. See the new example in 'examples/share-javascript'.
- Bug fixes in Session middleware.
- Added support for string-based paths with * for splat like /foo/*
- Before callbacks may now return promises that must be resolved before the route handler is executed.
- After callbacks may now return promises that must be resolved before the response from the route handler is returned.
ViewEngine
is now anEventEmitter
.- the built-in
Mustache
view engine now emitsbeforeRender
andafterRender
events. - Fixed bugs in
Flash
middleware.
after
had been left off of the public API of router, added it.
- Simplified and corrected code for
pipe
method on the request object for theParted
middleware. - Added
Session
middleware.
- Updated Parted dependency to 0.8.0.
- Mustache partials now work properly when using layouts.
- Routes now match in order added instead of longest-first.
- Added
Flash
middleware to emulate the flash method of Rails.
- Added
Error
middleware to translate rejected promises and thrown errors into an error response. Error
middleware is included by default in JSGI stacks constructed withbogart.build
.ParseForm
andParseJson
have been replaced withParted
in JSGI middleware stacks constructed withbogart.build
.
- Added
Parted
middleware to take advantage of the excellent streaming parsers provided by Parted. - Added multipart-form example to the examples directory to demonstrate usage of the Parted middleware.
- use Buffer.byteLength to determine the value for
Content-Length
headers, resolves Issue #11
bogart.redirect
now accepts a 2nd optional parameter which if present will be merged into the returned response object
- Add
before
method to the return frombogart.router
- Added support for mustache partials to the mustache template engine. This is unrelated to Bogart partials.
- Match
pathInfo
of "" to "/" if no route found for "" - Support dot in named parameters
- Made view engines registerable.
- Moved 'jade' and 'haml' renderers to their own packages: 'bogart-jade' and 'bogart-haml'.
- Removed node-deflate dependency becuase it was sometimes failing to compile when installed with npm.