Skip to content

Latest commit

 

History

History
86 lines (74 loc) · 2.95 KB

File metadata and controls

86 lines (74 loc) · 2.95 KB

Duckett HTML & CSS:

Chapter 2: “Text”

There are a variety of element tags that are used specifically to mark-up text:

There are also a variety of semantic tags that can be used to provide additional information for accessability and those reading your code, such as emphasis, acronyms/abbreviations, addresses, citations, quotes, and more.

  • see the link above to the MDN HTML Elements Reference to get a full list of semantic elements

Chapter 10: Ch.10 “Introducing CSS”

CSS allows you to create rules that affect how the website is styled/presented to the user. By referencing specific element types, id's, classes, or combinations of all three you can specifically target HTML elements to precicely control how it looks.

  • CSS can be applied to HTML element in-line, in page in the <head>, or linked via a filename.css external file
<link href="filename.css" type="text/css" rel="stylesheet" />
  • type="text/css" not required

CSS Selector Reference

selector {
    target property: value;
}

.selector { = class
#selector { = id
h1, h2, h3 { = multiple at once
header, h1 { = h1 of a specific section, in this case the header

Duckett JAVASCRIPT & JQUERY:

Chapter 2: “Basic JavaScript Instructions”

  • JavaScript is case sensitive, camelCase is the
  • Statements: individual instruction step to a computer ends in ;
  • Comments: notes about what your code is doing //
  • Variable: delcared via let, const, or var, holds a value
    • var is outdated not preferred
    • let variable = value;
    • must start with a letter, _, or $
    • can't use keywords
  • Data Types: string, number, boolean
  • Arrays: stores multiple values separated by commas
    • let array = [value1, value2, value 3];
    • index starts at position 0
    • methods can be applied to arrays
  • Expressions: evaluate into a value
  • Operators: used with expressions to calculate a value

Chapter 4: “Decisions and Loops”

Decisions have two components:

  1. An expression which is evaluated and returns a value
  2. A conditional statement that tells it what to do

Evaluating Operators

  • == equal to, '43' == 43
  • === strict equals '43' != 43
  • != not equals to
  • !== strict not equals to
  • < less than
  • > greater than
  • <= less than or equal to
  • >= greater than or equal to

Logical Operators

  • && AND
  • || OR
  • ! NOT

If and if else statements

if (condition){
    code to be executed;
}

if (condition1){
    code to execute if condition 1 is true;
} else {
    code to excute if condition 1 is false;
}