What is JavaScript?
The full text of this chapter, to read or revisit. To practise, do the exercises.
▶ Do the exercisesExercise 1 — Welcome to JavaScript!
JavaScript is a programming language that brings websites and applications to life, and it's one of the most popular in the world. It's what makes a page interactive, working alongside HTML (for structure) and CSS (for styling).
For now, we'll focus on pure JavaScript - learning the language itself without mixing in other technologies.
JavaScript vs Java
Despite the similar names, JavaScript and Java are completely different programming languages! It's like comparing a car and a carpet - they both start with "car" but they're totally different things.
Exercise 2 — What is JavaScript?
Which of the following best describes JavaScript?
Hint : Remember that JavaScript is a programming language, not a styling or markup language. It's also completely different from Java despite the similar name.
Exercise 3 — What Can JavaScript Do?
JavaScript is incredibly powerful and versatile. Here are some things you can create with JavaScript:
- Websites: Allows to make button clickable, send form, display data in a smart way, plenty of things! - Games: JavaScript can create everything from simple puzzle games to complex multiplayer experiences - Mobile apps: With frameworks like React Native, you can use JavaScript to build apps for phones and tablets
The list goes on, but let's not get ahead of ourselves. First, we'll start with the basics of the language itself!
Exercise 4 — Web Technologies: What Does Each Do?
Match each web technology with its primary purpose:
Exercise 5 — Why Start with Pure JavaScript?
In this course, we're starting by learning pure JavaScript before mixing it with HTML and CSS. Why is this a good approach?
Hint : Learning pure JavaScript first helps you understand the language itself. Later, you'll combine it with HTML and CSS, but starting with the basics makes everything clearer.