MCPcopy Index your code
hub / github.com/heroku/react-refetch / newError

Function newError

src/utils/errors.js:1–5  ·  view source on GitHub ↗
(cause)

Source from the content-addressed store, hash-verified

1export default function newError(cause) {
2 const e = new Error(parse(cause))
3 e.cause = cause
4 return e
5}
6
7function parse(cause) {
8 const { error, message } = cause

Callers 2

errors.spec.jsFile · 0.85
handleResponseFunction · 0.85

Calls 1

parseFunction · 0.85

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…