Skip to content

Commit 8a4ca90

Browse files
committed
doc: clarify rules for adding new built-in modules
Signed-off-by: Antoine du Hamel <duhamelantoine1995@gmail.com> PR-URL: #64648 Reviewed-By: Filip Skokan <panva.ip@gmail.com> Reviewed-By: Michaël Zasso <targos@protonmail.com> Reviewed-By: Ulises Gascón <ulisesgascongonzalez@gmail.com> Reviewed-By: Colin Ihrig <cjihrig@gmail.com> Reviewed-By: Marco Ippolito <marcoippolito54@gmail.com> Reviewed-By: Luigi Pinca <luigipinca@gmail.com> Reviewed-By: James M Snell <jasnell@gmail.com> Reviewed-By: Jake Yuesong Li <jake.yuesong@gmail.com> Reviewed-By: Richard Lau <richard.lau@ibm.com>
1 parent 8e52064 commit 8a4ca90

1 file changed

Lines changed: 5 additions & 3 deletions

File tree

doc/contributing/collaborator-guide.md

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -443,10 +443,12 @@ metadata. Raise a pull request like any other change.
443443

444444
Treat commits that introduce new core modules with extra care.
445445

446-
New modules must only be added with the `node:` prefix.
446+
New modules must only be added with the `node:` prefix, as `semver-minor`.
447447

448-
When adding promises to an existing API, add `/promises`
449-
(`inspector/promises`, etc.). Apply the `semver-major` label to the addition.
448+
When adding a "sub-module", e.g. a promise variant of an existing API (e.g.
449+
`node:inspector/promises`) that is available without the `node:` prefix, making
450+
the sub-module available without the prefix is possible behind a runtime flag,
451+
or as a `semver-major` change.
450452

451453
If the new module name is free in npm, register
452454
a placeholder in the module registry as soon as possible. Link to the pull

0 commit comments

Comments
 (0)