Design comparison
Solution retrospective
My search filter is working perfectly in the desktop browser but not functionally correct on mobile? Any feedback would be very much appreciated.
Community feedback
- @khach2010Posted about 2 years ago
Hi Eruj22,
thanks a lot for your valuable feedback. It's definitely help me a lot in improving yourself as developer. I'll take all of the needed improvements as you pointed out in the list with me for the next project.
Have a nice day
0 - @eruj22Posted about 2 years ago
Hi MT-LE,
I had a look into your code and it needs some improvements. Below I will make a list of what you can do to make your code better:
- if you are using VS code for code editor get Prettier extension. This will make your code pretty and more organized
- all the unnecessary imports should be deleted (e.g. useState and useEffect in Header.jsx)
- when you use eventListener inside useEffect you also need to return it to not have unnecessary leaks in the app:
useEffect(() => { window.addEventListener("resize", handleResize); return window.addEventListener("resize", handleResize); }, []);
- for making your app responsive you should use media queries inside styles and not use states for this (e.g. in DetailPage.jsx and FilterSearch.jsx)
- inside styles you are nesting elements too much (max 2 levels deep). Take a look here to find out mare about CSS specificity: https://blog.logrocket.com/how-css-works-understanding-the-cascade-d181cd89a4d8/
- remove all unnecessary comments (many are in style sheets)
- for improving styles you can use modules style sheets: https://create-react-app.dev/docs/adding-a-css-modules-stylesheet/
It turns out that it is quite a long list. Take your time with improvements are try to understand why it should be done in a different way. It takes hard work to improve yourself as developer and only you can make it work.
Have fun on your journey
0@khach2010Posted about 2 years ago@eruj22
Hi Eruj22, thanks a lot for your valuable feedback. It's definitely help me a lot in improving yourself as developer. I'll take all of the needed improvements as you pointed out in the list with me for the next project.
Have a nice day
0
Please log in to post a comment
Log in with GitHubJoin our Discord community
Join thousands of Frontend Mentor community members taking the challenges, sharing resources, helping each other, and chatting about all things front-end!
Join our Discord