Invocation And Performance Navigation - Study Mode

[#1] What is the inital step to set up a CSS Lazy Loading?
Correct Answer

(A) Fetching data

Explanation

Solution: The CSS Lazy Loading is begun with fetching the JavaScript and the CSS files.

[#2] What is the purpose of holding whatever tag you create in the attribute type?
Correct Answer

(B) To identify the scripting language

Explanation

Solution: A variable is created to hold whatever taag you create, and then branch the logic based on the value of type, which identifies it’s for JavaScript or for CSS.

[#3] What does the appendChild() method perform?
Correct Answer

(C) Appends a node as the last child

Explanation

Solution: The appendChild() method appends a node as the last child of a node.

[#4] What should be the value of the type attribute of a variable if the type of file is CSS?
Correct Answer

(C) text/css

Explanation

Solution: Since the type of file is CSS, the type attribute should hold the value text/css.

[#5] How to lazy load images?
Correct Answer

(B) Remove the src attribute

Explanation

Solution: The way we would lazy load images would be to alter the HTML of the page to remove the contents of the src attribute of each image. We could just move the contents of the src attribute to an attribute in the image tag of our own design, maybe the rel attribute.