Interview Q&A / Node.js
Node.js interview questions
The event loop on the server, streams, modules and building APIs with Express.
Prefer rapid revision? Practise Node.js short interview answers →
- What do the caret (^) and tilde (~) mean in package.json versions?
Caret allows updates that do not change the leftmost non-zero version number, so ^1.4.2 accepts 1.x.x at or above 1.4.2. Tilde allows only patch updates, so ~1.4.2 accepts 1.4.x at or above 1.4.2.
BeginnerQuick answer1 min read - What is semantic versioning and why does it matter for npm packages?
Semantic versioning uses MAJOR.MINOR.PATCH. Increase PATCH for bug fixes, MINOR for backward-compatible features, MAJOR for breaking changes, so users can judge upgrade risk from the number alone.
BeginnerQuick answer1 min read