Conduitry
/
contexty
Archived
1
Fork 0

adjust motivation section in readme

This commit is contained in:
Conduitry 2017-06-26 07:16:26 -04:00
parent 104afbe582
commit 0bd9f57b3b
1 changed files with 3 additions and 1 deletions

View File

@ -4,7 +4,9 @@
**Contexty** is a very simple implementation of a "thread-local storage"-esque concept for Node.js, based on asynchronous resources and `async_hooks`.
Typical usage and motivation: At the beginning of handling an HTTP request, you can create a new context. Elsewhere in your code, you can retrieve the current context and get/set values on it. The context is preserved for the duration of that HTTP request, but is kept separate for different HTTP requests.
## Motivation
At the beginning of handling an HTTP request, you can create a new context. Elsewhere in your code, you can retrieve the current context object and get/set values on it. The context is preserved for the duration of that HTTP request, but is kept separate for different HTTP requests. This all happens without you having to pass the current context object around.
## Requirements