Skip to content

Yank Express Application Generator, migrate Express tutorial to ESM - #45596

Merged
hamishwillee merged 13 commits into
mdn:mainfrom
Josh-Cena:express-esm
Nov 10, 2026
Merged

hamishwillee merged 13 commits into
mdn:mainfrom
Josh-Cena:express-esm

Conversation

@Josh-Cena

@Josh-Cena Josh-Cena commented Sep 9, 2026 •

Copy link
Copy Markdown
Member

Fix #41604.

There's no need not to use ESM. It offers top-level await, avoiding some very weird coding patterns. All documentation offers code examples in the ESM version.

Also removed Luxon, but not sure about modernizing the other dependencies. If agreed, they could be a follow-up tasks.

@github-actions github-actions Bot added Content:Learn Learning area docs (outside of one of the Learn:* subtags) size/m [PR only] 51-500 LoC changed labels Sep 9, 2026
@github-actions

github-actions Bot commented Sep 9, 2026 •

Copy link
Copy Markdown
Contributor
Preview URLs (25 pages)
External URLs (36)

URL: /en-US/docs/Learn_web_development/Extensions/Server-side/Express_Nodejs/development_environment
Title: Setting up a Node development environment


URL: /en-US/docs/Learn_web_development/Extensions/Server-side/Express_Nodejs/Displaying_data/Home_page
Title: Home page


URL: /en-US/docs/Learn_web_development/Extensions/Server-side/Express_Nodejs/Displaying_data/Template_primer
Title: Template primer


URL: /en-US/docs/Learn_web_development/Extensions/Server-side/Express_Nodejs/Introduction
Title: Express/Node introduction


URL: /en-US/docs/Learn_web_development/Extensions/Server-side/Express_Nodejs/mongoose
Title: Express Tutorial Part 3: Using a Database (with Mongoose)


URL: /en-US/docs/Learn_web_development/Extensions/Server-side/Express_Nodejs/routes
Title: Express Tutorial Part 4: Routes and controllers


URL: /en-US/docs/Learn_web_development/Extensions/Server-side/Express_Nodejs/skeleton_website
Title: Express Tutorial Part 2: Creating a skeleton website

(comment last updated: 2026-11-10 05:04:45)

@github-actions github-actions Bot added size/xl [PR only] >1000 LoC changed and removed size/m [PR only] 51-500 LoC changed labels Sep 9, 2026
@Josh-Cena
Josh-Cena force-pushed the express-esm branch 3 times, most recently from 2d61f42 to b6c16cd Compare September 9, 2026 20:53
const modelInstances = await SomeModel.find().exec();
```

## Setting up the MongoDB database

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

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

@hamishwillee FYI the steps here are very out of date and do not match what I see in my MongoDB interface. You may want to update these.

(But also as I said in the issue, I would prefer just getting rid of MongoDB.)

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

@Josh-Cena As you say, a problem for another day.

@github-actions github-actions Bot added the system [PR only] Infrastructure and configuration for the project label Sep 9, 2026
@Josh-Cena
Josh-Cena marked this pull request as ready for review September 9, 2026 23:13
@Josh-Cena
Josh-Cena requested review from a team as code owners September 9, 2026 23:13
@Josh-Cena
Josh-Cena requested review from dipikabh and hamishwillee and removed request for a team and dipikabh September 9, 2026 23:13
hamishwillee and others added 5 commits November 10, 2026 11:33
Match the example code (mdn/express-locallibrary-tutorial#369):

- Format BookInstance dates in UTC, so they aren't shown a day early
  west of UTC, and remove the note about that limitation.
- Delete the author identified in the URL rather than an id from a
  hidden form field, and correct the explanation.
- Redirect to book.url after updating a book.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
- Fix stale text left over from the generator and starter project
- Fix typo in Book detail page
- Update sample npm version and output, and the version prefix note
- Reword the PowerShell note
- Match the demo's viewport meta and Helmet comment
- Fix indentation of the Delete author snippet and explain it
- Fix date format in the BookInstance challenge
- Retake and compress the BookInstance list and Author detail screenshots

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
- Describe what server.js and routes/index.js actually do
- Clarify what the DEBUG variable turns on
- Correct the GraphQL description and match the ORM list form
- Drop the unsupported claim that CommonJS is legacy
- Use the due_back field name, not due_date
- Explain which dates are stored as midnight UTC

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The Express 5 API reference is now split into subpages, so the
expressjs.com/en/5x/api/#... anchors no longer work. Also fix the
express-router guide anchor and point the changelog link at the
GitHub releases page that it now redirects to.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
- Replace the Mongoose callback error-handling example, which no longer
  works in Mongoose 7+, with a Node readFile() callback example
- Say what express.urlencoded() and express.json() each parse
- Point the users route note at the running instructions, now later
- Remove "required" left over from CommonJS in the forms overview
- Explain the debug namespace in the deployment logging example
- Say that model modules export the model itself
- Link the MDN and Node ES modules pages in See also

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

@hamishwillee hamishwillee left a comment •

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

Thanks @Josh-Cena

I've scanned through this and used Claude to fix a number of relatively minor issues, some that were pre-existing.

Open to fixing up the other dependencies. This is a great base for that as a post process. Much appreciated.

PS Someone messed with the code ownership of the demo repo and I can't accept changes. I've asked for it to be merged. I'm not waiting on it.

@hamishwillee
hamishwillee merged commit d775e12 into mdn:main Nov 10, 2026
15 checks passed
@Josh-Cena
Josh-Cena deleted the express-esm branch November 10, 2026 05:27
pepelsbey added a commit to pepelsbey/mdn-content that referenced this pull request Nov 12, 2026
* upstream/main: (204 commits)
  [Editorial review] Add BiDi `network.setCacheBehavior` and `network.setExtraHeaders` pages (mdn#46140)
  build(deps-dev): bump @mdn/fred from 2.10.1 to 2.11.0 (mdn#46474)
  Reorder sections on HTML attribute pages (mdn#46483)
  Reorder sections on HTML element pages (mdn#46484)
  Fix live sample code block order in web API pages (mdn#46452)
  Move SVG attribute usage notes after examples (mdn#46458)
  Move SVG attribute elements section before examples (mdn#46459)
  Fix SuppressedError nesting in the `using` error handling example (mdn#46479)
  Editorial review: Document Web Audio render quantum size (mdn#46241)
  Remove the SVGAnimateColorElement page (mdn#46473)
  FF161 Relnote: Move WebTransport.anticipatedConcurrentIncoming{Uni|Bi}directionalStreams from 160 (mdn#46440)
  [WebExt] Screenshot updates to Nova (mdn#46270)
  build(deps-dev): bump cspell from 10.4.0 to 10.4.1 in the npm-dev group (mdn#46455)
  Update Firefox 160 release notes for WebDriver conforming changes. (mdn#46415)
  ci(deps): bump peter-evans/create-pull-request from 8.1.1 to 8.1.2 (mdn#46454)
  Move subtitles_en.vtt to shared-assets and update audio-video reference (mdn#46451)
  Yank Express Application Generator, migrate Express tutorial to ESM (mdn#45596)
  Fix heading sequence in web-api property pages (mdn#46450)
  Fix heading sequence in web-api interface pages (mdn#46448)
  Fix heading sequence in css-property pages (mdn#46447)
  ...

# Conflicts:
#	files/en-us/web/webdriver/reference/bidi/modules/network/index.md
#	files/sidebars/webdriver.yaml
pepelsbey added a commit to pepelsbey/mdn-content that referenced this pull request Nov 12, 2026
…epts

* upstream/main: (195 commits)
  [Editorial review] Add BiDi `network.setCacheBehavior` and `network.setExtraHeaders` pages (mdn#46140)
  build(deps-dev): bump @mdn/fred from 2.10.1 to 2.11.0 (mdn#46474)
  Reorder sections on HTML attribute pages (mdn#46483)
  Reorder sections on HTML element pages (mdn#46484)
  Fix live sample code block order in web API pages (mdn#46452)
  Move SVG attribute usage notes after examples (mdn#46458)
  Move SVG attribute elements section before examples (mdn#46459)
  Fix SuppressedError nesting in the `using` error handling example (mdn#46479)
  Editorial review: Document Web Audio render quantum size (mdn#46241)
  Remove the SVGAnimateColorElement page (mdn#46473)
  FF161 Relnote: Move WebTransport.anticipatedConcurrentIncoming{Uni|Bi}directionalStreams from 160 (mdn#46440)
  [WebExt] Screenshot updates to Nova (mdn#46270)
  build(deps-dev): bump cspell from 10.4.0 to 10.4.1 in the npm-dev group (mdn#46455)
  Update Firefox 160 release notes for WebDriver conforming changes. (mdn#46415)
  ci(deps): bump peter-evans/create-pull-request from 8.1.1 to 8.1.2 (mdn#46454)
  Move subtitles_en.vtt to shared-assets and update audio-video reference (mdn#46451)
  Yank Express Application Generator, migrate Express tutorial to ESM (mdn#45596)
  Fix heading sequence in web-api property pages (mdn#46450)
  Fix heading sequence in web-api interface pages (mdn#46448)
  Fix heading sequence in css-property pages (mdn#46447)
  ...

# Conflicts:
#	files/sidebars/webdriver.yaml
pepelsbey added a commit to pepelsbey/mdn-content that referenced this pull request Nov 12, 2026
…tication

* upstream/main: (186 commits)
  [Editorial review] Add BiDi `network.setCacheBehavior` and `network.setExtraHeaders` pages (mdn#46140)
  build(deps-dev): bump @mdn/fred from 2.10.1 to 2.11.0 (mdn#46474)
  Reorder sections on HTML attribute pages (mdn#46483)
  Reorder sections on HTML element pages (mdn#46484)
  Fix live sample code block order in web API pages (mdn#46452)
  Move SVG attribute usage notes after examples (mdn#46458)
  Move SVG attribute elements section before examples (mdn#46459)
  Fix SuppressedError nesting in the `using` error handling example (mdn#46479)
  Editorial review: Document Web Audio render quantum size (mdn#46241)
  Remove the SVGAnimateColorElement page (mdn#46473)
  FF161 Relnote: Move WebTransport.anticipatedConcurrentIncoming{Uni|Bi}directionalStreams from 160 (mdn#46440)
  [WebExt] Screenshot updates to Nova (mdn#46270)
  build(deps-dev): bump cspell from 10.4.0 to 10.4.1 in the npm-dev group (mdn#46455)
  Update Firefox 160 release notes for WebDriver conforming changes. (mdn#46415)
  ci(deps): bump peter-evans/create-pull-request from 8.1.1 to 8.1.2 (mdn#46454)
  Move subtitles_en.vtt to shared-assets and update audio-video reference (mdn#46451)
  Yank Express Application Generator, migrate Express tutorial to ESM (mdn#45596)
  Fix heading sequence in web-api property pages (mdn#46450)
  Fix heading sequence in web-api interface pages (mdn#46448)
  Fix heading sequence in css-property pages (mdn#46447)
  ...

# Conflicts:
#	files/sidebars/webdriver.yaml
pepelsbey added a commit to pepelsbey/mdn-content that referenced this pull request Nov 12, 2026
* upstream/main: (186 commits)
  [Editorial review] Add BiDi `network.setCacheBehavior` and `network.setExtraHeaders` pages (mdn#46140)
  build(deps-dev): bump @mdn/fred from 2.10.1 to 2.11.0 (mdn#46474)
  Reorder sections on HTML attribute pages (mdn#46483)
  Reorder sections on HTML element pages (mdn#46484)
  Fix live sample code block order in web API pages (mdn#46452)
  Move SVG attribute usage notes after examples (mdn#46458)
  Move SVG attribute elements section before examples (mdn#46459)
  Fix SuppressedError nesting in the `using` error handling example (mdn#46479)
  Editorial review: Document Web Audio render quantum size (mdn#46241)
  Remove the SVGAnimateColorElement page (mdn#46473)
  FF161 Relnote: Move WebTransport.anticipatedConcurrentIncoming{Uni|Bi}directionalStreams from 160 (mdn#46440)
  [WebExt] Screenshot updates to Nova (mdn#46270)
  build(deps-dev): bump cspell from 10.4.0 to 10.4.1 in the npm-dev group (mdn#46455)
  Update Firefox 160 release notes for WebDriver conforming changes. (mdn#46415)
  ci(deps): bump peter-evans/create-pull-request from 8.1.1 to 8.1.2 (mdn#46454)
  Move subtitles_en.vtt to shared-assets and update audio-video reference (mdn#46451)
  Yank Express Application Generator, migrate Express tutorial to ESM (mdn#45596)
  Fix heading sequence in web-api property pages (mdn#46450)
  Fix heading sequence in web-api interface pages (mdn#46448)
  Fix heading sequence in css-property pages (mdn#46447)
  ...

# Conflicts:
#	files/sidebars/webdriver.yaml
pepelsbey added a commit to pepelsbey/mdn-content that referenced this pull request Nov 12, 2026
…ollectors

* upstream/main: (186 commits)
  [Editorial review] Add BiDi `network.setCacheBehavior` and `network.setExtraHeaders` pages (mdn#46140)
  build(deps-dev): bump @mdn/fred from 2.10.1 to 2.11.0 (mdn#46474)
  Reorder sections on HTML attribute pages (mdn#46483)
  Reorder sections on HTML element pages (mdn#46484)
  Fix live sample code block order in web API pages (mdn#46452)
  Move SVG attribute usage notes after examples (mdn#46458)
  Move SVG attribute elements section before examples (mdn#46459)
  Fix SuppressedError nesting in the `using` error handling example (mdn#46479)
  Editorial review: Document Web Audio render quantum size (mdn#46241)
  Remove the SVGAnimateColorElement page (mdn#46473)
  FF161 Relnote: Move WebTransport.anticipatedConcurrentIncoming{Uni|Bi}directionalStreams from 160 (mdn#46440)
  [WebExt] Screenshot updates to Nova (mdn#46270)
  build(deps-dev): bump cspell from 10.4.0 to 10.4.1 in the npm-dev group (mdn#46455)
  Update Firefox 160 release notes for WebDriver conforming changes. (mdn#46415)
  ci(deps): bump peter-evans/create-pull-request from 8.1.1 to 8.1.2 (mdn#46454)
  Move subtitles_en.vtt to shared-assets and update audio-video reference (mdn#46451)
  Yank Express Application Generator, migrate Express tutorial to ESM (mdn#45596)
  Fix heading sequence in web-api property pages (mdn#46450)
  Fix heading sequence in web-api interface pages (mdn#46448)
  Fix heading sequence in css-property pages (mdn#46447)
  ...

# Conflicts:
#	files/sidebars/webdriver.yaml
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Content:Learn Learning area docs (outside of one of the Learn:* subtags) size/xl [PR only] >1000 LoC changed system [PR only] Infrastructure and configuration for the project

Projects

None yet

Development

Successfully merging this pull request may close these issues.

express-generator is ancient

2 participants