fregante / fregante/abort-utils
Add `delaySignal()`
Open
Nobody has claimed this yet.
enhancement
help wanted
- Dominant language
- TypeScript
- Stars
- 163
- Forks
- 1
- PR merge metrics
- No merged PRs in 30d
Description
Not AbortSignal.timeout(), but a transformer that accepts a signal and returns one that aborts later:
onAbort(AbortSignal.aborted(), () => console.log('original'))
onAbort(delaySignal(signal, 5000), () => console.log('delayed'))
// 0:00: original
// 0:05: delayed
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by reading the repository's existing AbortSignal and AbortController utilities and their tests to find the public entry point and conventions for transformed signals. Implement the delaySignal behavior shown in the issue, then add coverage confirming the original signal aborts immediately while the returned signal aborts after the delay.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- typescript
- Domain
- tooling
- Issue type
- Feature
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100