Question 6

developer creates a new web server that uses Node.js. It imports a server library that uses events and callbacks for handling server functionality.
The server library is imported with require and is made available to the code by a variable named server. The developer wants to log any issues that the server has while booting up.
Given the code and the information the developer has, which code logs an error at boost with an event?
  • Question 7

    A developer initiates a server with the file server,js and adds dependencies in the source codes package,json that are required to run the server.
    Which command should the developer run to start the server locally?
  • Question 8

    A developer wants to leverage a module to print a price in pretty format, and has imported a method as shown below:
    Import printPrice from '/path/PricePrettyPrint.js';
    Based on the code, what must be true about the printPrice function of the PricePrettyPrint module for this import to work ?
  • Question 9

    A developer executes:
    document.cookie;
    document.cookie = ' key=John Smith ' ;
    What is the behavior?
  • Question 10

    A developer copied a JavaScript object:

    How does the developer access dan's forstName,lastName? Choose 2 answers