Today I Learned: setTimeout() in JavaScript Today I explored how setTimeout() works in JavaScript ⏳ It allows you to execute a function after a specified delay Very useful for creating delays, animations, alerts, or API calls Example: setTimeout(() => { console.log("Hello after 2 seconds!"); }, 2000); Key Learning: Time is in milliseconds (1000ms = 1 second) Runs only once after the delay Helps in asynchronous programming Small concept, but very powerful in real-world projects! #JavaScript #WebDevelopment #FrontendDeveloper #CodingJourney #LearningEveryday
setTimeout() in JavaScript: Delayed Function Execution
More Relevant Posts
-
Built a simple game using HTML, CSS, and JavaScript 🎮 This project helped me understand: DOM manipulation Game loops with requestAnimationFrame Collision detection Event handling and animations It was a great hands-on way to strengthen my JavaScript fundamentals and problem-solving skills. #JavaScript #WebDevelopment #Frontend #Coding #Projects
To view or add a comment, sign in
-
🎯 Built a Number Guessing Game using JavaScript! This is a project I worked on earlier while learning JavaScript fundamentals. The game allows users to guess a random number between 1 and 100 within 10 attempts, with hints like “Too High” or “Too Low” to guide them. ([MDN Web Docs][1]) 🔧 Features: * Random number generation * Input validation * Previous guesses tracking * Remaining attempts display * Restart game functionality 💡 What I learned: * DOM manipulation * Event handling * Writing game logic * Improving UI with HTML & CSS This project was an important step in my learning journey. Since then, I’ve been improving my skills and currently working on more advanced and real-world projects 🚀 🔗 GitHub: https://lnkd.in/dsCDnqbC Excited to share more projects soon! #JavaScript #WebDevelopment #Frontend #LearningJourney #Growth
To view or add a comment, sign in
-
Advanced JavaScript — Day 1: Event Handling Today I dove into one of the most important topics in JavaScript — Event Handling. Once I got into the actual depth of how events work in the browser, I realized how much was happening behind the scenes that I had completely overlooked. Here's everything I covered today 👇 📌 What is an Event? 📌 addEventListener() 📌 The Event Object 📌 Event Bubbling 🫧 📌 Event Capturing (Trickling) 📌 stopPropagation() 📌 Event Delegation 🎯 📌 preventDefault() Event handling is everywhere in front-end development. Every button click, every form submission, every dropdown — it's all built on these exact concepts. Understanding bubbling, delegation, and the event object isn't optional if you want to write real-world JavaScript. Today was a great day of learning. On to the next topic. 🚀 #AdvancedJavaScript #JavaScript #EventHandling #EventBubbling #EventDelegation #100DaysOfCode #LearnInPublic #WebDevelopment #Frontend #Programming #CodingJourney #BuildInPublic
To view or add a comment, sign in
-
-
🚀 Today’s JavaScript Learning — DOM Stopwatch Project Today I worked on building a Stopwatch using JavaScript DOM. At first, the code was not working properly. The Stop button issue, event handling mistakes, and timer logic took me nearly 2 hours to debug. But finally I understood: ✅ DOM element selection ✅ EventListeners ✅ setInterval & clearInterval ✅ Debugging real errors ✅ Logical thinking improvement This small project taught me an important lesson: 👉 Programming is not about writing code fast — it’s about understanding problems patiently. Every mistake helped me learn deeper JavaScript concepts. Learning step by step and improving daily 🚀 #JavaScript #DreamTusk #DreamTuskTechnologies #WebDevelopment #DOM #LearningJourney #FrontendDeveloper
To view or add a comment, sign in
-
Learning by doing 💻 Remember the classic Snake game? 🐍 I created a Snake Game from scratch using HTML, CSS & JavaScript. This project helped me strengthen my fundamentals and logic-building skills. This is just the beginning—more projects coming soon! 🚀 Check it out and let me know what you think 👇 [https://lnkd.in/dXdYbw-U] #WebDevelopment #JavaScript #CodingJourney #LearningByDoing #FrontendDevelopment
To view or add a comment, sign in
-
Sometimes the best way to learn is by building small things just for fun. ❤️ I created Cursor Hearts, a small interactive project using HTML, CSS, and JavaScript where animated hearts appear and float upward as the cursor moves across the screen. This project started as a simple experiment with DOM manipulation, event listeners, and CSS animations, but it turned into a fun visual effect. Projects like this may be small, but they are great for understanding how JavaScript can dynamically create and control elements on a webpage. Small projects like this keep the learning process enjoyable while helping build stronger fundamentals. 🔗 Live Demo: https://lnkd.in/dAPmyFhv 💻 GitHub Repository: https://lnkd.in/dZ9FUn2W #javascript #webdevelopment #frontend #coding #learning #buildinpublic
To view or add a comment, sign in
-
JavaScript Number Guessing Game I just built a Number Guessing Game in JavaScript! 🎯 💡 Features: Random number generation (1-100) User input validation Hints: “Too high” / “Too low” Counts attempts Exit anytime This project helped me practice loops, conditionals, variables, and working with user input in JavaScript. Try it yourself! Code runs in the browser console or Node.js with prompt-sync. 💻 Skills practiced: JavaScript fundamentals, logic, problem-solving #JavaScript #Coding #WebDevelopment #LearningByDoing
To view or add a comment, sign in
-
-
Turn boring scroll into smooth animations — without writing complex JS. ✨ No GSAP setup ✨ No heavy libraries ✨ Just add attributes → done Build scroll effects, parallax, counters & more in minutes. 👉 Try MotionFlow: motionflow.dev #webdev #frontend #javascript #webanimation #nocode #devtools #buildinpublic
To view or add a comment, sign in
-
#Day7 Understanding Loops in JavaScript. I truly began to understand why they’re one of the most powerful concepts in programming. Loops are what turn static code into dynamic, intelligent systems. Whether you're processing user data, building animations, fetching API results, or running simulations, loops are doing the heavy lifting behind the scenes. Here are the types of loops listed in the diagram : => while Loop : It checks the condition before executing so if the condition is false from the start, the code never runs. => Do while loop : This is otherwise called the “optimistic” loop. It runs the code at least once before checking the condition. It is very useful for scenarios where you need user input or an initial action before validation. => For loop : This is my current favourite. Clean, readable, and perfect when you know the exact number of iterations or need control over the counter. Who else is currently learning or strengthening their JavaScript fundamentals? #M4ACELearningchallenge #LearningInPublic #JavaScript #WebDevelopment #CodingJourney
To view or add a comment, sign in
-
-
🚀 Just built a cool JavaScript mini-project! Today I worked on a simple but fun concept using DOM manipulation & mouse events 🎯 👉 Created a circle that follows the cursor in real-time 👉 Used event.clientX and event.clientY to track movement 👉 Applied dynamic styling with position: absolute 💡 This small project helped me understand: How browser events work Real-time UI interaction Importance of CSS positioning in JavaScript Sometimes, small projects teach BIG concepts 🔥 Excited to build more interactive UI experiences! #JavaScript #WebDevelopment #Frontend #Coding #Learning #DOM #BeginnerProjects
To view or add a comment, sign in
Explore content categories
- Career
- Productivity
- Finance
- Soft Skills & Emotional Intelligence
- Project Management
- Education
- Technology
- Leadership
- Ecommerce
- User Experience
- Recruitment & HR
- Customer Experience
- Real Estate
- Marketing
- Sales
- Retail & Merchandising
- Science
- Supply Chain Management
- Future Of Work
- Consulting
- Writing
- Economics
- Artificial Intelligence
- Employee Experience
- Workplace Trends
- Fundraising
- Networking
- Corporate Social Responsibility
- Negotiation
- Communication
- Engineering
- Hospitality & Tourism
- Business Strategy
- Change Management
- Organizational Culture
- Design
- Innovation
- Event Planning
- Training & Development