This project is part of my JavaScript learning journey. It demonstrates essential JavaScript concepts, including variables, conditionals, functions, loops, and DOM manipulation. The goal is to create a fully functional, interactive web page using only HTML, CSS, and JavaScript.
The project covers the following:
- Variable declarations using
letandconst - Handling user input
- Conditional logic using
if...else - Outputting results via:
console.log()- Modifying webpage content dynamically
- At least 2 custom functions for tasks like:
- Calculating totals
- Formatting strings
- Toggling webpage content
- Functions take inputs, process data, and return/display results
forloop examplewhileloop example- Looping through arrays, generating content, or creating countdowns
- Selecting HTML elements using
document.getElementById()andquerySelector() - Changing text and styles dynamically
- Listening for user events like clicks
- Creating and appending elements on the fly
📁 mastering-js-fundamentals
│── index.html # Main HTML structure
│── style.css # Styling
│── script.js # JavaScript logic
│── README.md # Project documentation
Your site is live at:
➡️https://dvchege.github.io/Mastering_javaScript/
- Download or Clone the Repository
git clone https://github.com/DvChege/mastering-js-fundamentals.git
2. **Open the Project Folder**
Navigate into the folder:
```bash
cd mastering-js-fundamentals
```
3. **Open index.html in a Browser**
Right-click `index.html` and choose **Open with Browser**.
---
## 🛠️ Technologies Used
* HTML5 — Structure
* CSS — Styling (optional)
* JavaScript — Functionality & interactivity
---
## 📖 Learning Outcomes
By completing this project, I learned how to:
* Declare and use variables effectively
* Implement conditionals to make decisions in code
* Create reusable functions
* Use loops for repetitive tasks
* Manipulate the DOM for interactive web pages
---
## ✨ Author
Josphat Chege
📧 Email: mailto:cjosphat964@example.com
💻 GitHub:https://github.com/DvChege