Skip to content

Commit

Permalink
Docs
Browse files Browse the repository at this point in the history
  • Loading branch information
akaspin committed Nov 10, 2010
1 parent eabdc96 commit 25b4116
Showing 1 changed file with 10 additions and 1 deletion.
11 changes: 10 additions & 1 deletion chain/cookie.md
Expand Up @@ -97,7 +97,7 @@ If for any reason you don't want to decorate `writeHead` method, just add
In this case `writeHead` method remains untouched and you can get all setted In this case `writeHead` method remains untouched and you can get all setted
cookies by `deploy` method, that returns `Array` of prepared cookies. cookies by `deploy` method, that returns `Array` of prepared cookies.


## Kaph chain usage ## Usage in Kaph chain


This module provides *operation* to use with *kaph*. Usage is similar to that This module provides *operation* to use with *kaph*. Usage is similar to that
described above. With one difference - operation creates a new object `cookies` described above. With one difference - operation creates a new object `cookies`
Expand Down Expand Up @@ -126,3 +126,12 @@ inside *kaph* handler.


## Pitfalls ## Pitfalls


All pitfalls of this module concluded that "kaph" decorates `writeHead` method
of `http.ServerResponse` instance. If you use any architecture, that also
decorates this method - use *Kaph cookie* **after** all other decorations.

For usage with *kaph* chain I recommend insert cookie *Operation* after all
others that may decorate `writeHead` method, and just before operations that
can write to `response`.


0 comments on commit 25b4116

Please sign in to comment.