Skip to content
Merged
Changes from 1 commit
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
Next Next commit
doc: add introduction sentence for CJS
  • Loading branch information
aduh95 committed Mar 27, 2022
commit c66777b5d3200ef5d4bf3893fd02f8a2014e8dd5
6 changes: 5 additions & 1 deletion doc/api/modules.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,11 @@
<!--name=module-->

In the Node.js module system, each file is treated as a separate module. For
CommonJS modules are the classic format to package JavaScript code for reuse. If
you are interested in writing browser-compatible code, check out the
[ECMAScript modules][] documentation.

In the CommonJS module system, each file is treated as a separate module. For
example, consider a file named `foo.js`:

```js
Expand Down