Day 2 of my Web Development Journey 💻 Today I learned some interesting concepts in JavaScript: dot notation, bracket notation, and optional chaining. We usually access object properties using dot notation like this: object.property But what if the property name starts with a number or contains special characters? In that case, dot notation doesn’t work. That’s where bracket notation comes in: object['property name'] It also allows us to use variables inside the brackets, which makes it more flexible. 😀 Another concept I explored today is optional chaining (?.). When trying to access a property from a nested object, if something doesn’t exist, the program can throw an error. Optional chaining helps avoid that by returning undefined instead of breaking the program. Learning step by step and enjoying the process 🚀 #WebDevelopment #JavaScript #LearningInPublic #Day2
Modina Khusbu Priya’s Post
More Relevant Posts
-
Day 26: Of web development course Practicing JavaScript DOM Events & Form Handling ⚡ Today I built a small interactive form to practice key DOM manipulation and event handling concepts in JavaScript. What I implemented: Used getElementById to select form elements Prevented default form submission using e.preventDefault() Added inline styling dynamically with onfocus and onblur events (background color change on input fields) Used onchange event on a dropdown to detect and respond to user selection changes Displayed real-time feedback using alert() What I learned: How to respond to different types of user interactions (focus, blur, change, submit) That DOM practice is best done through small, working examples like this The importance of preventDefault() when handling form submissions manually Next step: Fixing the missing username field and expanding to dynamic content updates instead of just alerts. Small steps, solid progress. 🧱💻 #webdevelopment #javascript #DOM #formevents #codingjourney #day26
To view or add a comment, sign in
-
-
🚀 40% of Websites Have This Common JavaScript Issue Imagine you're at a coffee shop, and you order a latte but get a cappuccino instead. That's basically what's happening when JavaScript variables get mixed up. In JavaScript, scope refers to where a variable is defined and accessible. A common issue is using `var` instead of `let` or `const`. Here's a quick example: ```javascript for , var i = 0; i 5; i++, setTimeout, , , = console.log, i, ; , 1000, ; ``` This code logs 5 to the console five times because `var` has a function scope, not a block scope. ✅ To fix this, use `let` or `const`: ```javascript for , let i = 0; i 5; i++, setTimeout, , , = console.log, i, ; , 1000, ; ``` This logs numbers 0 to 4 as expected. Did this help? Save it for later. Check if your website's JavaScript has this issue and fix it to improve performance. #JavaScript #WebDevelopment #CodingTips #TechEducation #WebDesign #FrontendDevelopment #JavaScriptSimplified #ScopeIssues #VarLetConst #CodingBestPractices #WebPerformance #DeveloperTips #CodeQuality #WebDevelopmentTips #LearnToCode
To view or add a comment, sign in
-
🚀 Just built a simple yet powerful project! 🎯 Live Digital Timer / Clock using JavaScript ⏰ This project displays real-time updates of time directly in the browser and helped me strengthen my understanding of core web development concepts. 🔧 Tech Stack: HTML CSS JavaScript 💡 Key Learnings: Using setInterval() for real-time updates DOM manipulation (getElementById) Dynamic styling using JavaScript Handling timing functions effectively ⚡ Challenges faced: Updating time continuously Ensuring proper script execution after DOM loads ✅ Successfully implemented a working live timer! 📈 Next Improvements: Add Date along with time 📅 Dark/Light mode 🌙 Dynamic background changes 🎨 I’m continuously learning and building. Feedback and suggestions are always welcome 🙌 #WebDevelopment #JavaScript #Frontend #CodingJourney #StudentDeveloper #LearningByDoing
To view or add a comment, sign in
-
🧑💻 CSS Selectors Cheat Sheet CSS selectors are patterns used to target and style HTML elements on a web page. They let you apply styles based on element type, class, ID, attributes, state, or relationships, enabling precise and flexible control over your site’s appearance. ✅ Basic Selectors ✅ Attribute Selectors ✅ Pseudo-Class Selectors ✅ Pseudo-Elements ✅ Combinators Save & share with your team! Download Our Free Full-Stack Developer Starter Kit ➡️ https://buff.ly/JbI0Qof --- If you found this guide helpful, follow TheDevSpace | Dev Roadmap, w3schools.com, and JavaScript Mastery for more tips, tutorials, and cheat sheets on web development. Let's stay connected! 🚀 #javascript #js #webdevelopment #CheatSheet #WebDevelopment #DataTypes
To view or add a comment, sign in
-
Just learned about the DOM (Document Object Model) in JavaScript! The DOM is what allows JavaScript to interact with HTML and CSS, making web pages dynamic and interactive. From changing text, styles, images, to handling button clicks — DOM manipulation is the backbone of modern web development. Example: ✔ Updating content instantly ✔ Creating new elements dynamically ✔ Responding to user actions Understanding DOM is a big step toward becoming a better frontend developer. Edure #JavaScript #WebDevelopment #Frontend #DOM #CodingJourney #LearnToCode
To view or add a comment, sign in
-
Built a simple web form with JavaScript validation! 🔹 Ensures correct user input 🔹 Displays real-time error messages 🔹 Improves usability and interaction This project helped me understand how important client-side scripting is in modern web development. Looking forward to learning more! 🚀 #JavaScript #WebDev #Projects #LearningByDoing#frontend
To view or add a comment, sign in
-
CSS :has() Changed Everything: The Selector That Eliminated JavaScript From My Stylesheets For two decades, CSS could not select parents based on their children. We wrote JavaScript - event listeners, MutationObservers, useEffect hooks - just to toggle class names for purely visual changes. That era is over. I just published a deep dive into CSS :has() covering real production patterns: form validation without JS, empty state handling, quantity-aware grids, and how it combines with container queries, nesting, and @layer to create something more expressive than Sass ever was. In three codebases I maintain, adopting :has() eliminated an average of 22% of component-level JavaScript. No bundle size increase. No framework dependency. Just CSS doing what it should have always been able to do. Read the full article: https://lnkd.in/g5JjFWnP #CSS #WebDevelopment #Frontend #ModernCSS #Performance #SoftwareEngineering #WebDev
To view or add a comment, sign in
-
🚀 Most Websites Struggle with This Simple JavaScript Concept I've seen many websites struggle with a basic JavaScript concept that can make or break user experience. As a frontend developer with 9+ years of experience, I'm here to simplify it for you. Imagine you're at a restaurant, and the waiter takes your order but forgets to tell the kitchen. That's basically what happens when JavaScript doesn't communicate with the server properly. It's a common issue that can lead to frustrated users and lost leads. The concept is called asynchronous programming. In simple terms, it means that JavaScript can send a request to the server without freezing the entire page. This is crucial for modern web applications. Here's a quick example: When you submit a form, JavaScript sends a request to the server to process the data. If done synchronously, the page would freeze until the server responds. Asynchronous programming prevents this. For instance, Google's search results page uses asynchronous programming to load search results and ads simultaneously. This keeps the page responsive and interactive. Did this help? Check if your website uses asynchronous programming effectively. A simple tweak can boost user experience and conversions. ✅ #WebDevelopment #JavaScriptSimplified #AsyncProgramming #UserExperience #WebDesign #CodingTips #FrontendDevelopment #WebDev #JavaScript #Programming #Coding #WebPerformance
To view or add a comment, sign in
-
🚀 JavaScript Practical Project Series – Project 4: Search Filter Excited to share my fourth project in this series! 💻 I built a Search Filter, where users can instantly filter results based on their input. This is a common feature used in many real-world applications. 🔹 Features: • Real-time search filtering 🔍 • Instant results as user types • Clean and responsive UI • Improved user experience 🔹 Tech Stack: HTML | CSS | JavaScript Through this project, I learned how to implement dynamic filtering, handle user input, and update the DOM efficiently. These hands-on projects are helping me understand how modern web applications work 🚀 More exciting projects coming soon! 🙌 🔗Live Project: https://lnkd.in/gVSttpfM 📁GitHub Repository: https://lnkd.in/gdmUqEj9 #JavaScript #WebDevelopment #FrontendDeveloper #CodingJourney #Projects #SearchFilter #BuildInPublic #DeveloperLife #100DaysOfCode #TechGrowth
To view or add a comment, sign in
-
🔥 10 JavaScript One-Liners Every Developer Should Know In this guide, we're sharing 10 tricks that you should know to up your JavaScript game. ✅ Swap Two Variables ✅ Check if a Value is an Array ✅ Generate a Random Integer (0 to N) ✅ Flatten a Deeply Nested Array ✅ Remove Duplicates from an Array ✅ Get the Last Element of an Array ✅ Get the Max or Min Value in Array ✅ Check if an Object is Empty ✅ Reverse a String ✅ Short-Circuit Default Values Save & share with your team! --- If you found this guide helpful, follow me, React.js | JavaScript Mastery for more tips, tutorials, and cheat sheets on web development. Let's stay connected! 🚀 #WebDevelopment #CheatSheet #Coding #CSS #Filters #UI #Frontend #JavaScript #ReactJS
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