-
-
Notifications
You must be signed in to change notification settings - Fork 372
Open
Labels
FeatureNew FeatureNew FeatureLiveComponentStatus: Waiting feedbackNeeds feedback from the authorNeeds feedback from the author
Description
In a LiveComponent, I use an input field with required
attribute. The action is triggered manually by a button. As a shortened example, my component markup looks like the following:
<input type="text" id="ean" name="ean" value="{{ ean }}" data-model="norender|ean"
required="required" class="form-control" autofocus>
<input type="submit" class="btn btn-primary" data-action="live#action" data-action-name="checkIn"
data-loading="addAttribute(disabled)" value="Submit">
Even if I leave the input field empty, the AJAX request is sent out. Shouldn't the JS code first run the browser's built-in form validation to check whether all fields are valid?
Metadata
Metadata
Assignees
Labels
FeatureNew FeatureNew FeatureLiveComponentStatus: Waiting feedbackNeeds feedback from the authorNeeds feedback from the author