I am Developer


Angular 11 Reactive Forms Validation Tutorial

Reactive form validation in Angular 11 app. In this tutorial, i will show you how to use reactive form validation in angular 11 app.

As well as, and you will learn how use reactive form validation in angular 11. And also use reactive form with formGroup for validation in angular 11 app.

Reactive Form Validation In Angular 11
Step 1 – Create New Angular App
Step 2 – Import Form Module
Step 3 – Add Code on View File
Step 4 – Use Component ts File
Step 5 – Start Angular App


#reactive form validation in angular 11 #angular 11/10/9/8/7 reactive forms validation example #angular 11 form validation example

Yogi Gurjar


Laravel 8 Form Validation Tutorial

Laravel 8 form validation example. In this tutorial, i will show you how to submit form with validation in laravel 8.

And you will learn how to store form data in laravel 8. Also validate form data before store to db.

How to Validate Form Data in Laravel 8

  1. Step 1 – Install Laravel 8 Application
  2. Step 2 – Configuring Database using Env File
  3. Step 3 – Create Model & Migration File For Form
  4. Step 4 – Create Routes
  5. Step 5 – Creating Controller
  6. Step 6 – Create Blade File For Form
  7. Step 7 – Start Development Server
  8. Step 8 – Run Laravel 8 Form Validation App On Browser


#laravel 8 form validation #laravel 8 form validation tutorial #laravel 8 form validation - google search #how to validate form data in laravel 8 #form validation in laravel 8

Laravel 8 Form Validation Example

In this tutorial we will see laravel 8 form validation example, form validation in laravel is very common functionalities and it is use in each and every website to validate form field.

Here, We will use has function in session to check error message in laravel 8. using this example you can check simple form validation as well as you can create your own custom validation in laravel 8.

Laravel 8 Form Validation Example


Read Also : Laravel 8 CRUD Operation Example


#laravel 8 form validation example #form validation #how to validate form in laravel 8 #form validation in laravel #laravel #laravel8

Edison  Stark

Edison Stark


Angular: Creating custom validator for Reactive Form field

Angular’s popular Reactive Forms functionality comes with a Validator class that contains some very basic built-in validators for form fields, such as required, email, minLength and maxLength. But sometimes we need to validate more complex rules that cannot be covered with the basic ones.

Fortunately, it is very easy to create and assign a custom validator to a form field.

Example case

I want to create a form that contains a custom reactive form field to accept phone numbers. You can see how to create a custom reactive form field with Material Design here.

My field has two parameters: the country and the actual phone number.

When I choose a country from the dropdown, my program converts this country into a country code.

For example: 30 for Greece, 81 for Japan, 1 for USA etc

Example phone number object:

   "country_code" : "30", 
   "national_number" : "2123456789", 
   "flag_class" : "gr"

I want to create a validator that checks if country code exists and if the number entered is a valid number for this country.

Image for post

#validator #angular #reactive-forms

Macess  Hulk

Macess Hulk


Reactive Forms in Angular 10 - How to Create a Login Form using Reactive Forms

Reactive forms are an alternative to creating forms in Angular. Most of the heavy lifting for creating reactive forms happens in the component class instead of the template (HTML file).

One of the big benefits of using reactive forms is that it makes testing easier. The reason for this is that all the code related to your form lives in the component class. Given this, you don’t need to access the template on your tests to test your form. Instead, you can simply write a unit test.

Module setup

The first step to implement a reactive form will be to import ReactiveFormsModule to your application’s module. This module can be imported from @angular/forms.

For simplicity purposes, as part of this example, I’ll be writing all the form related code inside the AppComponent. The following code snippet shows how to include the ReactiveFormsModule for you to start creating your first reactive form.

import { BrowserModule } from '@angular/platform-browser';
import { NgModule } from '@angular/core';
import { AppComponent } from './app.component';
import { ReactiveFormsModule } from '@angular/forms';
  declarations: [
  imports: [
  providers: [],
  bootstrap: [AppComponent]
export class AppModule { }

#angular #javascript #programming #reactive-forms