❤3
While working on the edit/delete functionality for my #ExpenseTracker app, I hit a pesky bug I now call the "remount trap." The edit modal wouldn't close after updating an expense, even though the Redux state updated fine. Why? React's component lifecycle was the a mess!
The Bug: When submitting the edit form, a Redux loading state triggered a full-screen loader in the parent component, unmounting the modal. When it remounted, the React Router useFetcher hook lost its state, preventing the modal from closing. A classic React gotcha!
The Fix: Adding a key to useFetcher({ key: edit-expense-${expenseId} }) persisted the form submission state across unmounts, letting the modal detect the success response and close properly.
Takeaway: Understanding React's reconciliation, component lifecycle, and hook state management is key to squashing bugs like this and optimizing performance. Once you see the magic behind React, debugging feels like solving a puzzle! 🧩
#TechVibe #ReactJS #Debugging #ExpenseTracker @alnova19
The Bug: When submitting the edit form, a Redux loading state triggered a full-screen loader in the parent component, unmounting the modal. When it remounted, the React Router useFetcher hook lost its state, preventing the modal from closing. A classic React gotcha!
The Fix: Adding a key to useFetcher({ key: edit-expense-${expenseId} }) persisted the form submission state across unmounts, letting the modal detect the success response and close properly.
Takeaway: Understanding React's reconciliation, component lifecycle, and hook state management is key to squashing bugs like this and optimizing performance. Once you see the magic behind React, debugging feels like solving a puzzle! 🧩
#TechVibe #ReactJS #Debugging #ExpenseTracker @alnova19
⚡1
Please, Ethio telecom, let me use what I paid for. Please, please 🙏
Hey guys! Curious if you use integration or end-to-end tests (like Cypress) in your apps? I've built apps without automated testing, but is it really crucial?🤔
let me now down in the comments
#TechVibe #debugging @alnova19
let me now down in the comments
#TechVibe #debugging @alnova19
Forwarded from Tech Nerd (Tech Nerd)
Media is too big
VIEW IN TELEGRAM
It’s far from perfect, but this is what I’ve managed to build so far. From here on, I’ll be working on this project seriously not just as a side project, but as a real product.
It might not work out, but it’s worth the shot. Plus, having something big to chase feels amazing.
Hope you all like it. 😊
@selfmadecoder
It might not work out, but it’s worth the shot. Plus, having something big to chase feels amazing.
Hope you all like it. 😊
@selfmadecoder
I’m starting a project for a client today, and it’s due on Sunday and it is not small one. I’m not sure if I can finish it in time, but I’m going to give it my best shot. God help me out🙏
#TechVibe #ClientWork #NewProjectStarted @alnova19
#TechVibe #ClientWork #NewProjectStarted @alnova19
❤2👏1
Forwarded from Birhan Nega
Battling tight deadlines in software engineering demands nerves of steel. 💪
Birhan Nega
Battling tight deadlines in software engineering demands nerves of steel. 💪
This one is for me right now😭
😁3
Hey guys, I know I didn’t post today — I was a little busy working on the backend of my new project. I’ve already designed the UI and implemented the static pages. Next, I’ll be working on the map and reverse geocoding for the real-time tracking logic.
#TechVibe #ParcelCourierProject @alnova19
#TechVibe #ParcelCourierProject @alnova19
❤2👏2
By the way, these are some of the pages I’ve built so far, what do you guys think?
#TechVibe #ParcelandCourier @alnova19
#TechVibe #ParcelandCourier @alnova19
❤5👌2
Forwarded from kirubel ⚡️
Real devs use React Query for server state, not boilerplate Redux.
I finally deployed the project and sent the link for review. After receiving their feedback, I worked on additional functionalities.
#TechVibe #ParcelCourierProject @alnova19
#TechVibe #ParcelCourierProject @alnova19
❤1