Describe how cross-origin resource sharing (CORS) is handled in Node.js.
Instruction: Explain the concept of CORS and how to implement CORS support in a Node.js application.
Context: This question tests the candidate's knowledge of web security principles, specifically CORS, and their ability to configure a Node.js application to safely interact with resources from different origins.
Updated
Official answer available
Read the opening below, then unlock the full answer and practical guidance.
To implement CORS in a Node.js application, one of the most straightforward...