Skip to main content
Journey Uncommon Logo
JourneyUncommon
mediumNodeJSAbortController cancellationSingle-choice MCQ

How does attaching a fresh `'abort'` listener to a signal that has *already* been aborted behave?

const ac = new AbortController(); ac.abort(); ac.signal.addEventListener('abort', () => console.log('fired'));