Skip to content

Commit

Permalink
Clarified About Modules section in about-packages-and-modules.mdx (#1148
Browse files Browse the repository at this point in the history
)

Updated the About Modules documentation section of
<https://docs.npmjs.com/about-packages-and-modules> to improve clarity
of messaging.

Co-authored-by: Gar <[email protected]>
  • Loading branch information
KCarlile and wraithgar authored Aug 12, 2024
1 parent 3ec803c commit 44e5382
Showing 1 changed file with 4 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -56,9 +56,11 @@ To be loaded by the Node.js `require()` function, a module must be one of the fo

In the context of a Node program, the `module` is also the thing that was loaded _from_ a file. For example, in the following program:

var req = require('request')
```
var req = require('request')
```

we might say that "The variable `req` refers to the `request` module".
The `req` variable refers to the `request` module returned by the `require()` function.

[about-scopes]: about-scopes
[private-pkgs]: about-private-packages
Expand Down

0 comments on commit 44e5382

Please sign in to comment.