Design comparison
Community feedback
- @petritnurediniPosted 10 months ago
Congratulations on completing the "Product Preview Card Component" project! 🎉 Your hard work is evident in your attention to detail and responsiveness. Here are some recommendations for further enhancement:
-
Semantic HTML:
- Great use of semantic elements like
<section>
. Consider addingaria-label
to buttons and links for improved accessibility. - For the
<img>
elements, ensure thealt
attributes are descriptive for better SEO and accessibility, likealt="Perfume Image"
.
- Great use of semantic elements like
-
CSS Practices:
- Flexbox or Grid: Good use of the grid layout. As you progress, experiment with Flexbox for more complex layouts.
- Shorthand Properties: Utilize CSS shorthand properties for margin, padding, font, etc., to make your code more concise.
-
Responsive Design:
- Your responsive design with media queries is well implemented. Test on various devices to ensure consistent behavior.
- Consider using relative units like
rem
or%
for font sizes and layout dimensions to enhance scalability.
-
Performance and Efficiency:
- Optimize image sizes for faster load times. Tools like TinyPNG can help.
- Minify your CSS for production to improve load times. Tools like CSS Minifier can be useful.
-
Code Organization:
- Maintain consistent indentation and spacing in your HTML and CSS for better readability.
- Consider organizing your CSS by separating layout, typography, and color styles for maintainability.
-
Further Learning and Resources:
- Explore CSS preprocessors like SASS or LESS for more efficient styling.
- Consider learning JavaScript to add interactivity to your projects.
Useful Resources:
- MDN Web Docs for deepening your understanding of HTML, CSS, and JavaScript.
- CSS-Tricks for practical tips and tricks in CSS.
- A11Y Project for accessibility best practices.
Keep pushing your limits and exploring new aspects of web development. Your journey is going great, and there's so much more exciting stuff to learn and create! 🚀
Marked as helpful1@xStephxPosted 10 months ago@petritnuredini thanks for advice! I followed all advices and will apply them in future projects. If you have any other suggestions feel free to text me!
1 -
- @AshongAbdallah06Posted 7 months ago
For the image element, you could make use of the
picture
element, which is an easier way to implement the image change on different viewports. And you wouldn't need any media queries for that.Code Example
<picture> <source srcset={desktop image here} media="(min-width: 600px)" /> <img src={mobile image here} alt="" /> </picture>
You can specify any width, depending on when you want the changes to occur. You can check it out more on MDN
Hope you find this helpful!
Marked as helpful0@xStephxPosted 7 months ago@AshongAbdallah06 thanks for your feedback! I will try using picture element, in some future projects. If you have any other suggestions feel free to text me!
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