TGViewer
Node JS Node JS @nodejs_lib · 1.96K subscribers
Post #277 1.2K
Hot Hook

Hot Hook is a simple and lightweight library for adding hot module replacement in NodeJS with ESM.

You know how in frameworks like React or VueJS, you edit a file and the page updates automatically without needing to refresh? Well, it's the same concept but for NodeJS.

Take an Express server, for example. The most common development process involves watching the entire project with tools like nodemon and restarting the whole server whenever a file changes. With Hot Hook, you no longer need to restart the entire server; you can make it so only the changed module/file is reloaded. This provides a much faster DX and feedback loop.

The library is designed to be very light and simple. It doesn't perform any dark magic, no AST parsing, no code transformation, no bundling. It just reloads the changed module.

https://github.com/julien-R44/hot-hook

✍️ @nodejs_lib
GitHub GitHub - Julien-R44/hot-hook: 🪝 Simple HMR for NodeJS + ESM 🪝 Simple HMR for NodeJS + ESM. Contribute to Julien-R44/hot-hook development by creating an account on GitHub.
  • 👍 2
More from @nodejs_lib
  1. Dec 12, 2025State QUIC в Node.js QUIC — это протокол транспортного уровня на базе UDP, созданный для з…
  2. Oct 25, 2025Команда npx — это мощный инструмент в экосистеме Node.js, который часто недооценивают, счи…
  3. Sep 8, 2025Как сериализовать данные из Node.js, чтобы они могли использоваться в других языках и сист…
  4. Aug 16, 2025Использование SQL в Node.js с Sequelize Реляционные базы данных используют SQL (Structured…
  5. Jul 25, 2025Building Microservices with Node.js: Explore microservices applications and migrate from a…
  6. Jul 23, 2025Стилизация текста в консоли Node.js В этом посте мы рассмотрим, как можно стилизовать текс…
Threads Profile ViewerView any public Threads profile without an account.Open ThreadLook →Writing with AI? Make it sound human.Metric37 rewrites AI drafts so they read naturally. Free AI detector, 1,500 words free.Try Metric37 →