How can we validate individual form field In Magento 2?
You can validate specific field using below code of line.
<script>
require([
'jquery',
'mage/mage',
], function($){
$( "#new-button" ).click(function() {
$('input[name="field_mobile"]').validation();
if(!$('input[name="field_mobile"]').validation('isValid')){
return false;
}
});
});
</script>
NOTE: make sure you have added data-mage-init='{"validation":{}}
in form tag.
I found this one to work:
$.validator.validateSingleElement('#input-id');
More about how it's implemented and used here: https://mage2.pro/t/topic/5504