Skip to content
Myr

Release 2.0.0beta3

Before adoption: this commit came in with the history the project adopted, so no landing records it.

authored by Tj Holowaychuk · committed by Tj Holowaychuk · parent 55143a9 · Browse files · 6 files+26 added−4 removed
This commit

State

Before adoption: this commit came in with the history the project adopted, so no landing records it.

Diff stats

6 files+26 added−4 removed

  • tests:+1 added−1 removed
  • other:+25 added−3 removed

6 files+26 added−4 removed

modified:bin/express+1 added-1 removed
9 unmodified lines
10/**11 * Framework version.12 */1314var version = '2.0.0beta2';14var version = '2.0.0beta3';1516/**17 * Add session support.18 */
432 unmodified lines
modified:docs/guide.md+4 added
781 unmodified lines
782A literal _Content-Type_ works as well:783784 res.contentType('application/json');785786Or simply the extension without leading `.`:787788 res.contentType('json');789790### res.attachment([filename])791792Sets the _Content-Disposition_ response header to "attachment", with optional _filename_.793
415 unmodified lines
modified:lib/express.js+1 added-1 removed
modified:test/response.test.js+1 added-1 removed
28 unmodified lines
29 });30 31 app.get('/text', function(req, res){32 res.header('X-Foo', 'bar');33 res.contentType('.txt');33 res.contentType('txt');34 res.send('wahoo');35 });36 37 app.get('/status', function(req, res){
550 unmodified lines
modified:History.md+18 added
122.0.0beta3 / 2011-03-09 3==================45 * Added support for `res.contentType()` literal6 The original `res.contentType('.json')`,7 `res.contentType('application/json')`, and `res.contentType('json')`8 will work now.9 * Added `res.render()` status option support back10 * Added charset option for `res.render()`11 * Added `.charset` support (via connect 1.0.4)12 * Added view resolution hints when in development and a lookup fails13 * Added layout lookup support relative to the page view.14 For example while rendering `./views/user/index.jade` if you create15 `./views/user/layout.jade` it will be used in favour of the root layout.16 * Fixed `res.redirect()`. RFC states absolute url [reported by unlink]17 * Fixed; default `res.send()` string charset to utf818 * Removed `Partial` constructor (not currently used)19202.0.0beta2 / 2011-03-07 21==================2223 * Added res.render() `.locals` support back to aid in migration process
490 unmodified lines
modified:package.json+1 added-1 removed