Required fields not working with netlify forms

Having issues with adding required to input fields and using netlify forms. It appears that netlify put the whole form inside its name="form-name" element but this then means you have hidden fields that are required, which the browser doesn’t like. An invalid form control with name='email' is not focusable. <input type=​"email" name=​"email" required=​"required" class=​"block w-full p-2 rounded-md text-redDark bg-white">​ is the error from chrome browser when trying to submit the form.

Using nuxt so unsure if that is causing the issues, however its set to static deployment so its generating HTML files so I don’t think this would where the issue is.

Ok it appears to be a nuxt issue. adding in the hidden field as it should be displayed solves the issue :slight_smile:

Thank you so much for coming back and letting us know. This will help future forums members that encounter something similar.