GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — doc: document non-node_modules-only runtime deprecation · nodejs/node@3ffe2e8

File tree

Expand file treeCollapse file tree
Open diff view settings
Filter options
  • doc/api
    • deprecations.md
Expand file treeCollapse file tree
Open diff view settings
Collapse file

‎doc/api/deprecations.md‎

Copy file name to clipboardExpand all lines: doc/api/deprecations.md
+15-7Lines changed: 15 additions & 7 deletions
  • Display the source diff
  • Display the rich diff
Original file line numberDiff line numberDiff line change
@@ -10,10 +10,11 @@ Node.js APIs might be deprecated for any of the following reasons:
1010
* An improved alternative API is available.
1111
* Breaking changes to the API are expected in a future major release.
1212

13-
Node.js uses three kinds of Deprecations:
13+
Node.js uses four kinds of deprecations:
1414

1515
* Documentation-only
16-
* Runtime
16+
* Application (non-`node_modules` code only)
17+
* Runtime (all code)
1718
* End-of-Life
1819

1920
A Documentation-only deprecation is one that is expressed only within the
@@ -25,10 +26,17 @@ deprecations below. Documentation-only deprecations that support that flag
2526
are explicitly labeled as such in the
2627
[list of Deprecated APIs](#list-of-deprecated-apis).
2728

28-
A Runtime deprecation will, by default, generate a process warning that will
29-
be printed to `stderr` the first time the deprecated API is used. When the
30-
[`--throw-deprecation`][] command-line flag is used, a Runtime deprecation will
31-
cause an error to be thrown.
29+
An Application deprecation for only non-`node_modules` code will, by default,
30+
generate a process warning that will be printed to `stderr` the first time
31+
the deprecated API is used in code that's not loaded from `node_modules`.
32+
When the [`--throw-deprecation`][] command-line flag is used, a Runtime
33+
deprecation will cause an error to be thrown. When
34+
[`--pending-deprecation`][] is used, warnings will also be emitted for
35+
code loaded from `node_modules`.
36+
37+
A runtime deprecation for all code is similar to the runtime deprecation
38+
for non-`node_modules` code, except that it also emits a warning for
39+
code loaded from `node_modules`.
3240

3341
An End-of-Life deprecation is used when functionality is or will soon be removed
3442
from Node.js.
@@ -140,7 +148,7 @@ changes:
140148
description: Documentation-only deprecation.
141149
-->
142150

143-
Type: Runtime (supports [`--pending-deprecation`][])
151+
Type: Application (non-`node_modules` code only)
144152

145153
The `Buffer()` function and `new Buffer()` constructor are deprecated due to
146154
API usability issues that can lead to accidental security issues.

0 commit comments

Comments
0 (0)
You are visitor 01402520 — GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.