HTML
HTML is not case sensitive that means,
<h1></h1>
<H1></H1>
<H1></h1>All of these are valid tags and they would work.
But it is not advised to use other than lowercase due to coding standards
Types of elements:
- Block elements: Block level elements creates their own block like structure. They get displayed on a new line on a page.
<h1>, <p> - Inline elements: Inline elements are those which get displayed in the current line if there is no break line tag introduced.
<span>
Javascript
Java script helps us interact with the DOM (Document Object Model)
That means we can edit HTML page elements in real time and do various tasks/actions on them
Scope
Scope terms to the availability and visibility of variables in a certain part of code
Types of scope:
- Global scope: In global scope variable is defined at the top of the program or outside of the function and is accessible from anywhere in the code
- Local scope: In local scope variable is defined inside a function and can only be accessed inside that particular function
Hoisting
Javascripts default behaviour moves up all the declarations to the first thing to be executed in this way, it only declares the elements and does not initialise them
Different between let and var?
The let keyword has a block scope but the var keyword has a function scope.
Most of the day was busy in the assignment, so these are the short notes for the day, I would study more and add them tomorrow.
Regards
–
Aryan Jasala
WordPress Engineer Trainee
