[WEEK #1] – 08 Introduction to JavaScript + Problem Set + Blog Question

Hey Guys. This week was not that hard at all. It was pretty simple because I knew some basic knowledge on JavaScript. This is also the first week so thats probably why the work is easy 😛 . Right now I am trying to set up my website so the file directory is easy and set up correct. All this weeks work is done though.


Problem Set

Blogging Questions

Describe how you connect an HTML file and a JS file.

Basically to link a HTML file and a JS file, you have to add a script tag with a source of the JavaScript file inside of the HTML file. Most of these tags are present inside of the body tag, inside the header, or anywhere. The following code sample below shows how the script tag should look like…

<script src="/problem-sets/assets/js/name.js"></script>

Describe the difference between writing code in the Chrome console and writing HTML/JS files that are then open in Chrome.

Basically you write code in the Chrome console to play/test things out. Once you want to implement ideas after testing, you then write code to the HTML/JS files. You can then open those files into a chrome browser to see your working JavaScript code. When writing code in the Chrome console, your code is not saved. Once you refresh the page your code is gone. It is good to test out quick fixes and to see if values are working using console.log.. I would suggest writing code in the HTML/JS File then opening the file using Live Server.

Join the Conversation

1 Comment

Leave a comment

Your email address will not be published. Required fields are marked *