diff --git a/doc/api/packages.md b/doc/api/packages.md index 53612252f15768..0c551bee7f5619 100644 --- a/doc/api/packages.md +++ b/doc/api/packages.md @@ -1099,8 +1099,8 @@ is a path. When a package has an [`"exports"`][] field, this will take precedence over the `"main"` field when importing the package by name. -When the value is a directory, [it may only be loaded via -`require()`](modules.md#folders-as-modules). +It also defines the script that is used when the [package directory +is loaded via `require()`](modules.md#folders-as-modules). ```cjs require('./path/to/directory'); // This resolves to ./path/to/directory/main.js.