The JavaScript Console

  1. How to get to Google Chrome's developers tool to access JavaScript console.
    1. Right clicking on the page to and selecting inspect. Clicking on the Console tab.
    2. Keyboard shortcuts, Cmd+Option+J on Mac or Control+Shift+J on Windows.

We will use console to run most of code in this course.

Write your first line of JavaScript Code

  1. Write your name in console and make your name as a data type called a string by putting in inside quotes.
  2. Create an alert window that says "Hello". Enter the code into console.
alert("Heelo");

We can test code snippet with console. If you want to shift to next line. You have to type shift + Return instead of just Return key.

results matching ""

    No results matching ""