Reading Notes for Day 7 of 201:
Domain Modeling
- Explain why we need domain modeling.
It helps us to have a common vocabulary and understanding for a project. With a good domain model, everyone knows what to expect and there are no misunderstandings or surprises.
HTML Table Basics
- Why should tables not be used for page layouts?
Because we have CSS for that now, and tables are clunky. (They reduce accessibility, produce ‘tag soup’ and are not automatically responsive.)
List and describe 3 different semantic HTML elements used in an HTML <table>.
tbody - defines the body of a table. tr - defines a row. td - defines the data that will be in each cell of the row.
Introducing Constructors
- What is a constructor and what are some advantages to using it?
A constructor is a factory that is ued to create objects.
How does the term this differ when used in an object literal versus when used in a constructor?
When this is used in an object literal it’s identifying information that’s already been assigned, when it’s used in a constructor it’s assigning the information.
-
Object Prototypes Using A Constructor
-
Explain prototypes and inheritance via an analogy from your previous work experience.
Second try - a prototype is like a blank invoice, there are common fields like company name and address, date and invoice number and amount and due date, those properties are inherited from a constructor, or a prototype assignment after the object is instantiated, but the specifics of that information is assigned when the object like a specific invoice is produced.
NOTE: This is a very common front end developer interview question
Bookmark and Review HTML Table Advanced Features and Accessibility
Things I want to know more about
I have always felt like I didn’t really understand how to iterate through and manipulate data in multidimensional arrays, so I will be working on getting very solid with that.