Express JS MCQ Questions And Answers
ExpressJS MCQ : This section focuses on "Basics" of Express JS. These Multiple Choice Questions (MCQ) should be practiced to improve the Express JS skills required for various interviews (campus interviews, walk-in interviews, company interviews), placements, entrance exams and other competitive examinations.
1. Express is a minimal and flexible _______ web application framework.
A. Node.js
B. React.js
C. Redux.js
D. Angular.js
View Answer
Ans : A
Explanation: Express is a minimal and flexible Node.js web application framework that provides a robust set of features for web and mobile applications. It is an open source framework developed and maintained by the Node.js foundation.
2. Express.js, or simply Express, is a _________ web application framework for Node.js
A. Front-end
B. Back-end
C. Database
D. None of the above
View Answer
Ans : B
Explanation: Express.js, or simply Express, is a back end web application framework for Node.js, released as free and open-source software under the MIT License.
3. Pug earlier known as ?
A. Terse
B. DRY
C. Express
D. Jade
View Answer
Ans : D
Explanation: Pug (earlier known as Jade) is a terse language for writing HTML templates
4. backlog arguments defines as?
A. A port number on which the server should accept incoming requests.
B. Name of the domain
C. The maximum number of queued pending connections
D. An asynchronous function that is called when the server starts listening for requests.
View Answer
Ans : C
Explanation: backlog : The maximum number of queued pending connections. The default is 511.
5. Which method requests that the server accept the data enclosed in the request as a modification to existing object identified by the URI?
A. GET
B. DELETE
C. PUT
D. POST
View Answer
Ans : C
Explanation: The PUT method requests that the server accept the data enclosed in the request as a modification to existing object identified by the URI. If it does not exist then the PUT method should create one.
6. This method of using values is called ?
A. filters
B. interpolation
C. inheritance
D. includes
View Answer
Ans : B
Explanation: This method of using values is called interpolation.
7. What are core features of Express framework?
A. Allows to set up middlewares to respond to HTTP Requests
B. Defines a routing table which can works as per HTTP Method and URL
C. Dynamically render HTML Pages
D. All of the above
View Answer
Ans : D
Explanation: All of the above are core features of Express framework.
8. _________ is a middleware which parses cookies attached to the client request object.
A. cookie
B. req.cookies
C. cookie-parser
D. None of the above
View Answer
Ans : C
Explanation: cookie-parser is a middleware which parses cookies attached to the client request object.
9. _____________ allows us to easily create a skeleton for a web application
A. Authentication
B. APIs
C. Debugging
D. Scaffolding
View Answer
Ans : D
Explanation: Scaffolding allows us to easily create a skeleton for a web application
10. In order to use Mongo with Express, we need a client API for node.
A. TRUE
B. FALSE
C. Can be true or false
D. Can not say
View Answer
Ans : A
Explanation: In order to use Mongo with Express, we need a client API for node.
Discussion