include response body in superagent errors for failed requests
npm install --save superagent superagent-use superagent-verbose-errors
To make any superagent request that fails append the response body to its error message:
const superagent = require('superagent-use')(require('superagent')) superagent.use(require('superagent-verbose-errors'))
To only include the response body for certain errors:
const superagent = require('superagent-use')(require('superagent')) superagent.use(require('superagent-verbose-errors')({ filter: res => res.status === 400 }))
RetroSearch is an open source project built by @garambo | Open a GitHub Issue
Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo
HTML:
3.2
| Encoding:
UTF-8
| Version:
0.7.4