Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

events: graduate Event, EventTarget, AbortController #35949

Closed
wants to merge 1 commit into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion doc/api/cli.md
Original file line number Diff line number Diff line change
Expand Up @@ -210,7 +210,7 @@ changes:
description: --experimental-abortcontroller is no longer required.
-->

Experimental `AbortController` and `AbortSignal` support is enabled by default.
`AbortController` and `AbortSignal` support is enabled by default.
Use of this command-line flag is no longer required.

### `--experimental-import-meta-resolve`
Expand Down
5 changes: 3 additions & 2 deletions doc/api/events.md
Original file line number Diff line number Diff line change
Expand Up @@ -1137,14 +1137,15 @@ setMaxListeners(5, target, emitter);
<!-- YAML
added: v14.5.0
changes:
- version: REPLACEME
pr-url: https://github.com/nodejs/node/pull/35949
description: No longer experimental.
- version: v15.0.0
pr-url: https://github.com/nodejs/node/pull/35496
description:
The `EventTarget` and `Event` classes are now available as globals.
-->

> Stability: 1 - Experimental

The `EventTarget` and `Event` objects are a Node.js-specific implementation
of the [`EventTarget` Web API][] that are exposed by some Node.js core APIs.
Neither the `EventTarget` nor `Event` classes are available for end
Expand Down
18 changes: 12 additions & 6 deletions doc/api/globals.md
Original file line number Diff line number Diff line change
Expand Up @@ -20,10 +20,12 @@ accessible.
## Class: `AbortController`
<!--YAML
added: v15.0.0
changes:
- version: REPLACEME
pr-url: https://github.com/nodejs/node/pull/35949
description: No longer experimental.
-->

> Stability: 1 - Experimental

<!-- type=global -->

A utility class used to signal cancelation in selected `Promise`-based APIs.
Expand Down Expand Up @@ -172,24 +174,28 @@ Used to print to stdout and stderr. See the [`console`][] section.
## `Event`
<!-- YAML
added: v15.0.0
changes:
- version: REPLACEME
pr-url: https://github.com/nodejs/node/pull/35949
description: No longer experimental.
-->

<!-- type=global -->

> Stability: 1 - Experimental

A browser-compatible implementation of the `Event` class. See
[`EventTarget` and `Event` API][] for more details.

## `EventTarget`
<!-- YAML
added: v15.0.0
changes:
- version: REPLACEME
pr-url: https://github.com/nodejs/node/pull/35949
description: No longer experimental.
-->

<!-- type=global -->

> Stability: 1 - Experimental

A browser-compatible implementation of the `EventTarget` class. See
[`EventTarget` and `Event` API][] for more details.

Expand Down
2 changes: 0 additions & 2 deletions lib/internal/abort_controller.js
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,6 @@ const {
} = require('internal/event_target');
const {
customInspectSymbol,
emitExperimentalWarning
} = require('internal/util');
const { inspect } = require('internal/util/inspect');

Expand Down Expand Up @@ -89,7 +88,6 @@ const kSignal = Symbol('signal');
class AbortController {
constructor() {
this[kSignal] = createAbortSignal();
emitExperimentalWarning('AbortController');
}

get signal() { return this[kSignal]; }
Expand Down