Basic Validation in Ionic

Dear All

I have one Form with input field username and one submit button

I want to validate for required field before clicking submit button

How do i do this ?

Please answer in Ionic 4 with sample code and understanding less code

Regards
Shabbir Sahiwala

Check out Josh Morony’s tutorial. (You can’t go wrong with Morony.)

It is updated for Ionic4, I think.

This would be done via the base framework’s solution. If you are using Angular, you can use Reactive Forms to do this. Assume Vue and React have similar solutions. There are tons of tutorials on this.

Remember, Ionic is just the UI layer, the business logic (like validation) lives with the framework (Angular).

Thanks VictorNorman,

I rechecked thrice times but found some errors being it is in IONIC 3 version.

Please do handy need code for about basic validation

Regards

I can’t help with ionic 3. I don’t know about it.

Vue does have similar solution to validation. There are plugins like Vuetify, vee validation, and vue form generator that can be used for vue validation.

1 Like

Okay, thank you very much.:+1: