To Do This Week:
NO CLASS on Monday January 16th – MLK DAY. We will meet on Wednesday the 18th.
CodeAcademy – just the lessons, not the projects
Learn Javascript :
1. “Welcome to Learn JavaScript”,
2. “Introduction to JavaScript“, “Variables,”
3. “Conditionals”
Read (optional): Eloquent Javascript:
Class
JavaScript Lecture/Demo: Variables and Conditionals
Workshop
Change Circles Script
Download the Circles file (control click page) or get the source code and make a new file in Sublime text. Then, with your partner, make changes. First talk about what 3 things you want to change in the script. Then list the steps needed for each change. Try to find the JavaScript code. Use ChatGPT or ask me.
Remember, if your script stops working. Command + Option + J opens the console with the line of the error. Or “inspect element” and look for the Console in the panel.
Notes:
- In Sublime Text go to Tools>Developer>New Snippet
- In the <content> tag and between <![CDATA[ …… ]]> add the following code:
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="utf-8">
<title> </title>
<link rel="stylesheet" href="css/styles.css">
<meta name="viewport" content="width=device-width, initial-scale=1">
</head>
<body>
<script src="js/scripts.js"></script>
</body>
</html>
Remove comments for line six and set your trigger word (such as html): <tabTrigger>html</tabTrigger> - Save your snippet in a file ending in “sublime-snippet.” On Mac, user created snippets are saved at:
Users/”Your User Name”/Library/Application Support/Sublime Text 3/Packages/User