The JavaScript Console
- How to get to Google Chrome's developers tool to access JavaScript console.
- Right clicking on the page to and selecting inspect. Clicking on the Console tab.
- 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
- Write your name in console and make your name as a data type called a string by putting in inside quotes.
- 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.