I want to validate the form on our Magento 2.3 store instant. So when a value is added into the input field, it should validate this instant and add some css class or id to the input field.

In that case we can add a validation check to the input, so the customer knows that the input is right.

This is quite easy for M1, but I can not find a solution for M2.

How can we achieve that?

  • Use onkey up event and validate using jquery – Bhavin Shah Apr 8 '19 at 19:52
  • @BhavinShah Thanks! Any idea how to achieve this? – JGeer Apr 9 '19 at 6:33

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.