ditto/packages/utils/abort.ts
2025-02-17 15:32:18 -06:00

6 lines
184 B
TypeScript

/** Creates an `AbortError` object matching the Fetch API. */
function abortError() {
return new DOMException('The signal has been aborted', 'AbortError');
}
export { abortError };