𝗧𝗵𝗲 𝗺𝗼𝗺𝗲𝗻𝘁 𝘆𝗼𝘂𝗿 𝗥𝗲𝗮𝗰𝘁 𝗮𝗽𝗽 𝗵𝗮𝘀 𝗺𝗼𝗿𝗲 𝘁𝗵𝗮𝗻 𝟯 𝗻𝗲𝘀𝘁𝗲𝗱 𝗰𝗼𝗺𝗽𝗼𝗻𝗲𝗻𝘁𝘀, 𝗽𝗿𝗼𝗽 𝗱𝗿𝗶𝗹𝗹𝗶𝗻𝗴 𝘀𝘁𝗼𝗽𝘀 𝗯𝗲𝗶𝗻𝗴 𝗺𝗮𝗻𝗮𝗴𝗲𝗮𝗯𝗹𝗲. 𝗜𝘁 𝗷𝘂𝘀𝘁 𝗯𝗲𝗰𝗼𝗺𝗲𝘀 𝗻𝗼𝗶𝘀𝗲. Learned about two things this week that made my React apps feel complete. 𝗖𝗼𝗻𝘁𝗲𝘅𝘁 𝗔𝗣𝗜 is a 𝗱𝗮𝘁𝗮 𝘀𝗵𝗮𝗿𝗶𝗻𝗴 𝗺𝗲𝗰𝗵𝗮𝗻𝗶𝘀𝗺 that lets you pass data across nested and sibling components without threading props through every layer. No more passing data five levels deep just to reach one component. React Router has three approaches most people don't know are different: • 𝗗𝗲𝗰𝗹𝗮𝗿𝗮𝘁𝗶𝘃𝗲 - you define routes as JSX components. Clean and readable • 𝗗𝗮𝘁𝗮 - handles loaders and actions alongside routing • 𝗙𝗿𝗮𝗺𝗲𝘄𝗼𝗿𝗸 - full setup with conventions baked in Built a mini project combining both. Context API managing shared state. Declarative routing handling navigation between pages. Seeing them work together in one project made everything click faster than any tutorial could. Sharing the demo below. Would love feedback on it. At what point did React's ecosystem stop feeling overwhelming and start feeling like leverage? Devendra Dhote Sheryians Coding School #ReactJS #JavaScript #FrontendDevelopment #WebDevelopment #ContextAPI #ReactRouter #StateManagement #ComponentArchitecture #LearningInPublic #BuildInPublic #DevCommunity #DeveloperJourney #SideProject #CodingProjects
More Relevant Posts
-
If you're learning React and still confused about hooks… You're not alone. 👉 A lot of people know how to use hooks, but not when to use them. And that’s where things start going wrong. Here are 5 React hooks that actually matter 👇 🔹 useState Manages component state and triggers re-render when data changes. Used in almost every app , but overusing it can make your logic messy. 🔹 useEffect Handles side effects like API calls and external updates. Most misused hook , bad dependencies = bugs + performance issues. 🔹 useRef Stores values without causing re-renders and accesses DOM directly. Super useful for focus control, timers, and tracking previous values. 🔹 useContext Removes prop drilling by sharing data across components. Great for global state , but don’t treat it like a full state manager. 🔹 useNavigate Controls navigation programmatically inside your app. Commonly used for redirects after login, logout, or form actions. --- Here’s the truth 👇 React isn’t hard. Bad understanding of hooks is. Stop memorizing. Start building. 💬 Which hook confused you the most when you started? #ReactJS #FrontendDeveloper #JavaScript #MERNStack #WebDevelopment #Coding #LearnInPublic
To view or add a comment, sign in
-
-
When React State Management Finally Clicked 🚀 For ages, I wrestled with props drilling in React apps – passing data down through every component like a game of hot potato. 😩 It felt messy and slow, especially in bigger projects. Then it hit me: Context API is my new best friend! No more prop chains. The Old Way (Messy) ❌ The Smart Way (Clean) ✅ Now, any component grabs useContext(UserContext) – boom, done! Only updates what needs to. ⚡ Key Takeaway Stop fighting props. Embrace Context (or Redux for complex stuff) to keep code simple and scalable. This shift made my apps cleaner and faster to build. What's your "aha" moment with React? Share below! 👇 #ReactJS #JavaScript #Frontend #WebDev #ReactTips #Coding #DevLife #Performance #LearnToCode #SoftwareEngineering #Developer #TechTips 🔥💻
To view or add a comment, sign in
-
-
I Built My Own React Practice Lab 🚀 I spent the last few months doing something different: moving from "Writing Code" to truly understanding state. Most tutorials show you the result. Mine shows you the mechanics. What I Built: → A custom State Watcher that visualizes how state flows in real-time → A Registry System to isolate and master every complex React pattern → 10+ interactive demos covering everything from useEffect to Redux What You Get: ✅ Core Fundamentals (Props, Mapping, Component Architecture) ✅ Hooks Mastery (useEffect, useMemo, useRef, and more) ✅ Global State (Redux Toolkit, RTK Query, Auth patterns) ✅ Advanced Routing (React Router 6.4+ with Data Loaders & Nested Routes) This lab is the interactive engine behind my React Learning Portal—built to make the "hard parts" visible and intuitive. Know someone stuck on React? Share this with them. What React concept gave you the most trouble? Drop it in the comments 👇 🔗 Try the Live Lab: https://lnkd.in/dJ5X--4u 📖 Explore the Hub: https://lnkd.in/dkMYXNrh #ReactJS #WebDevelopment #Frontend #Redux #LearningByDoing #React #Saylani #SMIT
To view or add a comment, sign in
-
Debug Battle Completed in 30 Minutes Just finished a React Debug Battle where I fixed a broken Habit Tracker app and made it fully functional in under 30 minutes. Live Demo: https://lnkd.in/gFwFUKeS GitHub Repo: https://lnkd.in/ggw3eSQw Here’s what I worked on : Fixed React Context crash where useContext was returning undefined Resolved state initialization issues causing runtime errors Corrected reduce, map, and filter logic Fixed date handling bugs affecting streak and progress tracking Improved toggle and update logic Aligned UI with state for edit and complete flows This was less about fixing errors and more about understanding data flow, handling edge cases, and making the application stable. Time taken approximately 30 minutes Key takeaway : Debugging improves problem solving far more than writing code from scratch. It forces you to understand how systems actually work. Daneshwar Verma Ritik Rajput Devendra Dhote Sheryians Coding School #ReactJS #FrontendDevelopment #Debugging #JavaScript #WebDevelopment #BuildInPublic
To view or add a comment, sign in
-
-
🌐 Today’s MERN Concept: React Context API — Avoiding Prop Drilling As part of my MERN learning journey today, I explored the React Context API, a built‑in solution to avoid deeply nested prop passing (prop drilling). ✨ What I learned today: The Context API helps React applications share data across components without manually passing props through every level. Here are today's key insights: 🔹 Create a Context to store shared state 🔹 Wrap components inside a Provider 🔹 Consumer components access values directly 🔹 Helps simplify global state like themes, user data, app settings 🔹 Works best for light shared state — not a replacement for Redux My biggest realization today “Context API reduces unnecessary complexity — it lets the right data reach the right component without clutter.” Understanding this helped me see how React apps maintain scalable and cleaner architecture. More MERN learnings tomorrow! #MERN #ReactJS #ContextAPI #FrontendDevelopment #JavaScript #LearningJourney
To view or add a comment, sign in
-
-
Today I learned Context API and built a dark/light theme switcher to understand it properly. Here's what I actually built: A product card that switches between light and dark mode using a toggle button. No prop drilling. No passing functions 5 levels deep. Just Context. The thing that clicked for me: Before Context API, if a child component needed data from the top of the app, you'd pass it down as props through every component in between even the ones that don't need it. That's called prop drilling and it gets messy fast. Context API solves this by creating a "global store" that any component can just plug into directly. How I set it up in 3 steps: 1️⃣ Created the context : ThemeContext with themeMode, lightTheme, and darkTheme as defaults 2️⃣ Wrapped the whole app in <ThemeProvider> and passed the real state + functions as value 3️⃣ In any component that needs it just call useTheme() and the theme state is right there. No props. No drilling. The useEffect part was interesting too. Whenever themeMode changes, it removes the old class from the <html> tag and adds the new one. Tailwind picks that up and switches the whole UI instantly. One toggle. Two lines of state. The whole app responds. Still small projects — but the concepts are getting real now. Learning this from Hitesh Choudhary and Chai Aur Code What did you use before you discovered Context API? I was passing props everywhere... Github CodeBase : https://lnkd.in/d-gxU5Dw #LearningInPublic #ReactJS #ContextAPI #JavaScript #Frontend #WebDevelopment #BuildInPublic #100DaysOfCode
To view or add a comment, sign in
-
-
setState does not work as you expect Do you think setState works like this: setCount(1) console.log(count) // should be 1, right? Wrong. It's still 0 (or the prev value). And if you don't understand WHY... You'll spend hours debugging something that isn't even a bug. This is Post 6 of the series: 𝗥𝗲𝗮𝗰𝘁 𝗨𝗻𝗱𝗲𝗿 𝘁𝗵𝗲 𝗛𝗼𝗼𝗱 Where I explain what React is actually doing behind the scenes. Here's what's actually happening 👇 setState doesn't update state. It queues a request to React. React then decides WHEN to process it. Not your code. React. That's why the value after setState is still the old one... because the component hasn't re-rendered yet. Now here's where it gets interesting. Call setState 3 times in one click? You'd expect 3 re-renders. React does it in 1. That's called Batching React's built-in performance superpower. It groups all your updates, processes them together, and re-renders once. But batching also leads to one of the most confusing bugs beginners face: setCount(count + 1) setCount(count + 1) // Expected: 2 // Actual: 1 😐 Both calls read the SAME stale snapshot of count. So React queues the same value twice. How to fix this? setCount(c => c + 1) setCount(c => c + 1) // Now it's: 2 ✅ Functional updates always get the latest queued value, not the stale snapshot. One tiny change in how you write setState. Massive impact on how your app behaves. Follow Farhaan Shaikh if you want to understand React more deeply. 👉 Read the previous post: Using index as key is dangerous in list: https://lnkd.in/dPQyScAT #ReactJS #JavaScript #WebDevelopment #Frontend #BuildInPublic #LearnInPublic #ReactUnderTheHood #FrontendDeveloper #Programming #TechStudent
To view or add a comment, sign in
-
Ever been stuck deciding what film to watch with your partner, endlessly scrolling Netflix? I've been building a side project called Movie Swiper, a collaborative film-matching app for when you and someone else can never agree on what to watch. You can try it out here: https://lnkd.in/eRS9Q76h The idea is simple: both people swipe on films independently, and when you both swipe right on the same one, it's a match. The stack I went with: → Next.js (App Router) + TypeScript for the frontend → Fastify + Apollo Server for the API → Prisma + PostgreSQL for the database → Turborepo monorepo to tie it all together → Deployed on Vercel + Railway It's been a great excuse to go deep on GraphQL with React Server Components, cookie-based auth across a monorepo, and Framer Motion for the swipe animations. Still a few things left to polish and I've got some plans to add new features, but it's at a point where I can start sharing and get some feedback on it. Give it a try and let me know what you think 👇 #NextJS #GraphQL #TypeScript #SideProject #WebDev
To view or add a comment, sign in
-
I thought React Context API would make my life easier. It didn’t. In fact, it confused me more than anything at the start. Here’s what I struggled with: Everything felt like “magic” Data was flowing without props, and I had no idea how or why. It worked, but I couldn’t explain it. Unexpected re-renders One small change and suddenly a large part of my app was re-rendering. Where do I even create context? Global or inside a component? My folder structure became messy. Debugging was difficult With props, I could trace the flow easily. With Context, it felt hard to track what was happening. What actually helped me understand it: I focused on understanding the flow instead of memorizing (Context → Provider → Consumer) I built a small project using only Context (No Redux, no shortcuts) I learned when not to use it Context is powerful, but not suitable for everything Now, Context API no longer feels confusing. It makes sense, and that’s when it becomes useful. Still learning and improving. Aqlix IT Solutions Hitesh Sharma Adarsh Priyadarshi Himanshu C. Mukesh Yadav Sagar Choudhary Vanshika . #React #WebDevelopment #BeginnerDeveloper #MERN #LearningInPublic
To view or add a comment, sign in
-
-
🎬 I built my biggest React project so far — a Movie App with a funny twist on the legendary EgyBest — after learning React over the past few weeks. I pushed myself to build a real-world, fully functional application as a challenge… and this is the result 👇 🎥 Demo in the video below ✨ Features: • Search for any movie using an API • View detailed movie information • Rate movies ⭐ • Add movies to a watched list • Store data using localStorage • Delete movies from the list 🛠 Tech I used & learned: • React (Components, Props, State) • useState & useEffect • Custom Hooks (built my own reusable logic) • API integration (fetching data) • Conditional rendering • Event handling • Local Storage • Basic CSS for styling 🧠 What I learned: • How to structure a real-world React application • Managing state across multiple components • Persisting data in the browser ⚡ Biggest challenge: • Keeping the watched list synced correctly with localStorage This project is a big step forward for me, and I’m excited to keep improving 🚀 🔗 GitHub: https://lnkd.in/d6Uu-Xr6 I’d really appreciate your feedback 🙌 #ReactJS #ReactDeveloper #FrontendDeveloper #JavaScriptDeveloper #WebDevProjects #BuildInPublic #CodingJourney #JuniorDeveloper
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