Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found

Submitted

responsive IP Tracker using flex box css

@Youssef-elmohamadi

Desktop design screenshot for the IP Address Tracker coding challenge

This is a solution for...

  • HTML
  • CSS
  • JS
  • API
3intermediate
View challenge

Design comparison


SolutionDesign

Community feedback

@Aggressive-Mohammed

Posted

Hello Youssef Mohammadi!

Congratulations on completing the challenge. You did awesome! Your HTML structure is well-organized and demonstrates a solid understanding of semantic elements. However, here are some recommendations and comments in terms of web development best practices:

  1. File Organization and Dependencies CSS Order: Normalize.css should be the first stylesheet since it resets default browser styles, ensuring consistent styling across browsers. Load it before any custom CSS.
<link rel="stylesheet" href="assets/css/normalize.css" /> <link rel="stylesheet" href="assets/css/all.min.css" /> <link rel="stylesheet" href="assets/css/master.css" /> CSS Loading Strategy: If master.css is large, consider using media="all" or even lazy loading it with the media="print" trick for faster page load times, especially on slower networks.

External Font Optimization: Consider loading fonts more efficiently using the rel="preload" strategy for better performance.

<link rel="preload" href="https://fonts.googleapis.com/css2?family=Rubik:ital,wght@0,300..900;1,300..900&display=swap" as="style"> 2. HTML Semantics and Accessibility Form Element: Wrap the search input and button in a <form> element to improve accessibility and user experience. This will also allow users to submit the form by pressing the "Enter" key. <form onsubmit="searchIp(); return false;"> <input type="text" /> <button type="submit"> <i class="fa-solid fa-angle-right"></i> </button> </form> Labels for Inputs: Add a label to the text input for accessibility, especially for screen readers.

<label for="ip-search">IP Address</label> <input type="text" id="ip-search" placeholder="Search for IP..." /> Descriptive Alt Text: If you plan to use icons, provide meaningful descriptions via alt attributes or consider using the aria-label attribute if the <i> tag does not support alt text.

  1. Accessibility Improvements Interactive Elements: Ensure that the button has a role="button" and focus/hover states for accessibility.

Use appropriate landmarks like <header> for the header and <section> for different parts of your UI to improve semantic structure.

<header class="header"> <!-- content --> </header> Heading Structure: Use headings like <h1>, <h2>, etc., to describe the content for better structure and SEO. The current structure lacks headings which might affect how the page is understood by screen readers and search engines.

Example:

<h1>IP Tracker</h1> 4. JavaScript Best Practices Deferred Loading: Move your JavaScript to the end of the <body> or use the defer attribute to prevent blocking the initial render of your page.
0

Please log in to post a comment

Log in with GitHub
Discord logo

Join 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