From d54cf15366458ac748d42a80809da05a398b7d25 Mon Sep 17 00:00:00 2001 From: Declan de Wet Date: Sat, 12 Dec 2015 00:38:47 +0200 Subject: [PATCH] add notes on debugging requests - closes #47 --- contributing.md | 5 ++++- readme.md | 10 ++++++++++ 2 files changed, 14 insertions(+), 1 deletion(-) diff --git a/contributing.md b/contributing.md index 638cd6f..a25e036 100644 --- a/contributing.md +++ b/contributing.md @@ -36,10 +36,13 @@ $ make lint To lint the source and run the tests: -``` +```bash $ npm test +# or, for optional request logging: +$ NODE_DEBUG=request npm test ``` + To create a coverage report: ``` diff --git a/readme.md b/readme.md index cb7e562..78cbd07 100644 --- a/readme.md +++ b/readme.md @@ -182,6 +182,16 @@ roots-contentful also provides a convenient view helper called `asset` that allo img(src!= asset(post.image, {w: 100, h: 100, q: 50})) ``` +### Debugging Requests + +This extension makes network requests. If you need to log requests for debugging, set your `NODE_DEBUG` environment variable to `request`. + +For example, in a `roots compile` command: + +``` +$ NODE_DEBUG=request roots compile --verbose +``` + ### License & Contributing - Details on the license [can be found here](license.md)