Sobes.tech
Junior — Middle

Can you name popular frameworks used in Node.js for server-side application development?

sobes.tech AI

Answer from AI

Popular frameworks for developing server-side applications on Node.js:

  • Express.js — the most common minimalist framework for creating web applications and APIs.
  • Koa.js — a modern framework from the creators of Express, using async/await for cleaner code.
  • NestJS — a progressive framework built on TypeScript, with an architecture inspired by Angular, suitable for large applications.
  • Hapi.js — a powerful framework with rich functionality for building APIs and servers.

Example of a simple server on Express.js:

const express = require('express');
const app = express();

app.get('/', (req, res) => {
  res.send('Hello, world!');
});

app.listen(3000, () => {
  console.log('Server is running on port 3000');
});