I Can’t Believe it’s JS411

Sasha Garsson
2 min readApr 8, 2023

--

Can you explain the purpose of each type of HTTP Request when using a RESTful web service?

  • GET: tells an application that we are requesting some sort of information.
  • POST: tells an application that it needs to create something.
  • PUT: is an update.
  • DELETE: removes something from an application.

What’s a test pyramid? How can you implement it when talking about HTTP APIs?

It describes the different types of tests available. Test types are arranged where the base is represented by the test type of the highest quantity. Moving higher in the pyramid, each level is represented by the type with the lower number of tests.

An example by Robert C. Martin:

What is the “demultiplexer”?

The demultiplexer is a combinational logic circuit designed to switch one common input line to one of several separate output lines.

What’s the difference between “blocking” and ‘non-blocking’ functions?

Blocking refers to operations that block further execution until that operation finishes while non-blocking refers to code that doesn’t block execution and returns immediately.

What are the main security implementations within NodeJS?

  • SQL Injection
  • Cross-Site Scripting
  • Command Injection
  • Local/Remote File Inclusion
  • Denial of Service
  • Directory Traversal
  • LDAP Injection

Explain the “path” module in NodeJS.

Node. js provides you with the path module that allows you to interact with file paths easily. The path module has many useful properties and methods to access and manipulate paths in the file system.

--

--