Design comparison
SolutionDesign
Community feedback
- @tatasadiPosted about 1 month ago
Good job on completing this challenge! The structure is solid, and I like how you've handled the form and the success message. Here are a few suggestions to make the code even better:
-
Accessibility: Use
h1
as the page title- Every page should have an
h1
tag, as it's essential for accessibility and SEO. If there isn't a visible one, you can add a hiddenh1
using a screen-reader-only class (likesr-only
) to improve accessibility for screen readers. It helps users and search engines understand the main focus of the page. - In this case, the most logical hidden
h1
could be something like "Newsletter Sign-Up." You can keep it visually hidden but readable for screen readers.
- Every page should have an
-
Use proper button text
- There's a small typo in the button text: "Subscribe to monthly newletter" should be "Subscribe to monthly newsletter."
-
Form validation
- You’ve already included a "Valid email required" message, but it could be enhanced with proper ARIA attributes to help screen readers understand the form's error state. For example, using
aria-live="polite"
on the error message span would announce errors in real-time.
- You’ve already included a "Valid email required" message, but it could be enhanced with proper ARIA attributes to help screen readers understand the form's error state. For example, using
Keep up the great work! You're almost there, and with these tweaks, the code will be even stronger!
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