Skip to content

Please include the current WHATWG proposal #2

@bakkot

Description

@bakkot

There is an existing WHATWG proposal for adding a addAbortCallback method to AbortController. This was explicitly intended to be the path towards having cancelation in ECMAScript, by adding that method and then having ES require AbortController with .abort() and .signal and AbortSignal with .aborted and .addAbortCallback(). WHATWG could then extend those classes.

ES methods which take a signal would just use the public interface, per our general convention of consuming arguments by their public interface (as decided in the Set methods proposal).

This is somewhere between your "option B" and "option C" and is I think overwhelmingly the best option. I think it would be best to present just this suggestion, not a bunch of other options.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions