Skip to content

Conversation

@elysdir
Copy link

@elysdir elysdir commented Jan 6, 2026

Adding info about some terms that aren't explained anywhere in this intro tutorial page. Feel free to modify as desired--I just want this page to explain what CJS, ESM, and .mjs mean before using those terms.

Description

Adding info about some terms that aren't explained anywhere in this intro tutorial page.

Validation

Just adding some text.

Related Issues

Check List

  • I have read the Contributing Guidelines and made commit messages that follow the guideline.
  • I have run pnpm format to ensure the code follows the style guide.
  • I have run pnpm test to check if all tests are passing.
  • I have run pnpm build to check if the website builds without errors.
  • I've covered new added functionality with unit tests if necessary.

Adding info about some terms that aren't explained anywhere in this intro tutorial page. Feel free to modify as desired--I just want this page to explain what CJS, ESM, and .mjs mean before using those terms.

Signed-off-by: Jed Hartman <logos-github@kith.org>
@elysdir elysdir requested a review from a team as a code owner January 6, 2026 01:54
@vercel
Copy link

vercel bot commented Jan 6, 2026

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Review Updated (UTC)
nodejs-org Ready Ready Preview Jan 6, 2026 1:55am

@github-actions
Copy link
Contributor

github-actions bot commented Jan 6, 2026

👋 Codeowner Review Request

The following codeowners have been identified for the changed files:

Team reviewers: @nodejs/nodejs-website

Please review the changes when you have a chance. Thank you! 🙏

## An Example Node.js Application

The most common example Hello World of Node.js is a web server:
The most common example Hello World of Node.js is a web server. You can choose between two versions of this example: one using the CommonJS (CJS) module system, using the filename extension `.js` or `.cjs`, and another using the ES Modules (ESM) system, using the filename extension `.mjs`. For more information, see [Understanding MJS and CJS](https://rgbstudios.org/blog/modules-explained-mjs-cjs).
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for the contribution. I'd prefer if we linked to Node.js documentation (maybe something like https://nodejs.org/api/esm.html#modules-ecmascript-modules ) or MDN for explanations of the module systems

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Additionally, .js can be both ESM or CJS

@codecov
Copy link

codecov bot commented Jan 6, 2026

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 74.72%. Comparing base (8c5a7dd) to head (4204acd).
✅ All tests successful. No failed tests found.

Additional details and impacted files
@@            Coverage Diff             @@
##             main    #8518      +/-   ##
==========================================
+ Coverage   74.70%   74.72%   +0.01%     
==========================================
  Files         102      102              
  Lines        8956     8956              
  Branches      305      305              
==========================================
+ Hits         6691     6692       +1     
+ Misses       2263     2262       -1     
  Partials        2        2              

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants