By @alesanchezr and other contributors at 4Geeks Academy
This tutorial is part of a bigger group of tutorials about web development, this repository focuses only on The DOM.
Estas instrucciones están disponibles en 🇪🇸 español 🇪🇸
-
How to select elements from your website.
-
Manipulate them with JavaScript (change styles, add event listeners).
-
Remove elements programmatically.
-
Change your entire website without a refresh.
- Introduction to HTML
- Introduction to CSS
- Introduction to JavaScript
- Introduction to The DOM ← You are here now 🔥
- Using events & The DOM
- Object Oriented Programming
You can open these exercises in just a few seconds by clicking: Open in Codespaces (recommended) or Open in Gitpod.
Once you have VSCode open, the LearnPack exercises should start automatically. If exercises don't run automatically, you can try typing on your terminal:
$ learnpack start
Clone the repository in your local environment and follow the steps below:
- Make sure you have learnpack,
node.js
version v14+, and jest v27 installed. This is the command to install the learnpack-cli and jest:
$ npm i @learnpack/[email protected] [email protected] -g
-
Clone or download this repository. Once you finish downloading, you will find a new folder with a subdirectory "exercises" that contains all the exercises within.
-
Install the learnpack plugin to test and compile vanillajs:
$ learnpack plugins:install learnpack-dom
- Start the tutorial/exercises by running the following command from the root of the project:
$ learnpack start
Each exercise is a small vanillajs website containing the following files:
- index.js: represents the entry JavaScript file that will be executed when the website loads.
- index.html: represents the HTML entry for the website.
- style.css: your website styles, they have to be imported from the index.html
- README.md: contains exercise instructions.
- test.js: you don't have to open this file, it contains the testing script for the exercise.
Note: The exercises have automatic grading, but it's very rigid and strict, my recommendation is to not take the tests too serious and use them only as a suggestion, or you may get frustrated.
Thanks goes to these wonderful people (emoji key):
-
Alejandro Sanchez (alesanchezr), contribution: (coder) 💻, (idea) 🤔, (build-tests)
⚠️ , (pull-request-review) 🤓, (build-tutorial) ✅, (documentation) 📖 -
Paolo (plucodev), contribution: (bug reports) 🐛, (coder) 💻, (translation) 🌎
This project follows the all-contributors specification. Contributions of any kind are welcome!
This and many other exercises are built by students as part of the 4Geeks Academy Coding Bootcamp by Alejandro Sánchez and many other contributors. Find out more about our Full Stack Developer Course, and Data Science Bootcamp.