So this is going to be a pretty quick video about the chrome javascript developer Cantal.
So before we actually dive into writing javascript code in the syntax we're going to start by figuring
out where we write the code.
And so in chrome one of the places we can do that is a javascript developer con..
So as we mentioned a few times Chrome has great developer tools some of which we've already seen like
the H Tim L and C Ss.
Inspector you can click the magnifying glass.
Click an element.
View the HGA now we can edit things needed him team and we can edit and view the success.
So we've seen that before.
To get here we can right click and inspect element or we can also go to View developer developer tools
.
And there's a shortcut here that you see command option.
So that's to get to the elements tab but you'll notice there's another tab over here which says con.
.
So this is the javascript developer con..
So in a nutshell this is a place where we can go and write javascript in our browser so developers don't
write full javascript applications in this console here just like developers don't write an entire style
sheet in the browser using this VSS inspector.
What you use it for is interacting with C assess or understanding how something works or testing something
out and then you go make the changes in your CSSA file.
So down the line we'll do the same thing with a javascript.
We'll use the console to play around with games to test things out but then we'll actually implement
a full javascript file that persists and that we save to our to our machine rather than just in the
browser.
So we are going to start out by writing our javascript inside of the chrome console and that won't last
very long.
It's just going to be a quick easy way for us to get up and going without having to focus on setting
up a project setting up our files and linking them together correctly.
We'll just open up her browser and type in javascript here.
So to illustrate how the javascript console works I have some pre-written code that I'm going to paste
in and execute before I do that though.
I just want to point out that the focus here is not on the syntax so don't panic.
We're going to spend lots of time going over how this code works in future videos.
What is the focus here.
Is the process.
So all I want you to understand I can put some code here.
It doesn't matter what the code actually does it just put some code there and then I can hit enter and
it will be executed.
So this code happens to do a simple animation.
It adds five pixels to the width of the image every 100 milliseconds.
So hasn't done anything yet.
As soon as I hit enter though it starts running.
Likewise I can type other code.
So here's a very simple program just going to pop up a little message for me.
Hello everyone.
And I hit enter and that pop up is executed and that code runs.
So that's all I want to show about the javascript console.
You can pop it up on any page using command option J or by going to view developer javascript console
or by opening up the elements inspector and clicking on cons..
So we're going to spend a lot of time here.