Chrome console not printing the console.log in Javascript course


I tried to go through the course on my MacBook pro and then my windows pc same results.

Can you post a screenshot of your code as well?

1 Like

1 Like

There the problem is, replace your script tag with mine:

<script src="index.js"></script>

Explanation: You can visit this for more information, HTML script tag, But in my own words, the source attribute or better known in coding as “src” should be inside the script attribute and there is no need to add the semi-colon after giving a URL, it is mostly only used when we add inline-styles, so you should always include any URL or address inside the first tag.

Some examples of URL or Address attributes:

<script src="something.js"></script>
<link rel="stylesheet" href="styles.css" />