reading-notes

Class 201.07 Tuesday 18th July

Notes

##

Q&A’s

The DOM, objects and tables are all fundamental parts of what goes into building a dynamically generated website.

Domain Modeling

  1. Explain why we need domain modeling.

    Domain modeling is the process of creating a conceptual model for a specific problem. The more efficiently we can solve the problem, the less resources ones application will run (e.g. an objects prototype when it runs more than once)

HTML Table Basics

  1. Why should tables not be used for page layouts?

    They are not responsive, and don’t transfer well to different screen sizes

  2. List and describe 3 different semantic HTML elements used in an HTML <table>.

    <th>, <td>, <tr> Table Header, Table Data, Table Row

Introducing Constructors

  1. What is a constructor and what are some advantages to using it?

    constructor is a special method used to initialize and create objects of a class, they are more efficient.

  2. How does the term this differ when used in an object literal versus when used in a constructor?
    • In an object literal, the term “this” refers to the object itself, representing the current instance of the object within the object’s scope. It allows you to access and modify properties and methods of the object.
    • In a constructor, the term “this” also refers to the object being created, but it represents the new instance being constructed, rather than an existing instance. It allows you to set and initialize properties and methods for the newly created object during the construction process.

Object Prototypes Using A Constructor

  1. Explain prototypes and inheritance via an analogy from your previous work experience. (NOTE: This is a very common front end developer interview question)
    • Prototypes: protocols for assessing risk in customers based on the law
    • Inheritence: business-specific (or even anecdotal) playbooks for different customers in different sectors

Bookmark and Review

References