Git Product home page Git Product logo

fewpjs-reviewing-server-communication-quiz's Introduction

Quiz: Reviewing Server Communication

???

Reviewing Server Communication

?: Choose which of the following is NOT part of the process of programming "favoriting" a social media post.

( ) A click event on a heart icon triggers a function. (X) The source HTML file is updated to display a filled-in heart icon. ( ) The DOM is updated to display a filled-in icon. ( ) A message is sent to the server when the click event runs.

?: AJAX refers to:

( ) another name for fetch(). ( ) a particular method from the jquery library. (X) a technique used for sending and receiving data on the web without a page refresh. ( ) a way to render HTML pages.

?: Choose the correct code sample for creating an event that uses fetch() to receive data and update the DOM.

( )

fetch("http://api.open-notify.org/astros.json").then(function(response) {
  return response.json();
});

(X)

fetch("http://api.open-notify.org/astros.json")
  .then(function(response) {
    return response.json();
  })
  .then(function(json) {
    console.log(json);
  });

( )

fetch("http://api.open-notify.org/astros.json").then(function(json) {
  console.log(json);
});

( )

fetch("http://api.open-notify.org/astros.json");

?: The following code is a correct way to make a web request using fetch():

fetch("https://anapioficeandfire.com/api/books")
  .then(resp => resp.json())
  .then(json => console.log(json));

(X) True ( ) False

?: Which of the following technologies is NOT involved in using AJAX?

( ) JSON ( ) the JavaScript event loop (X) CSS ( ) Promises

?: Browsers are able to run many different applications and tasks at what seems like the same time by utilizing a(n):

(X) asynchronous execution model ( ) synchronous execution model

?: The following snippet represents a synchronous block of code:

let tooMuchData = oneFetch("http://genome.example.com/...");
let lis = document.querySelectorAll("li");
console.log(tooMuchData);

( ) False (X) True

?: The following code represents an asynchronous block of code:

oneFetch("http://genome.example.com/...", tonOfGeneticData =>
  sequenceClone(tonOfGeneticData)
);
let lis = document.querySelectorAll("li");

(X) True ( ) False

?: After a call to fetch, the catch function ___

( ) can only be used once. ( ) sets up a handler for when the request is resolved. (X) invokes its callback when there is an error in the request. ( ) can only be called after a call to then.

???

fewpjs-reviewing-server-communication-quiz's People

Contributors

drakeltheryuujin avatar rrcobb avatar sgharms avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.