ngSubmitonSubmit
ngSubmit is a directive in Angular that is used to handle form submissions. It is applied to the form element and allows you to specify a method to be called when the form is submitted. When the user triggers a form submission, for example, by clicking a submit button or pressing Enter in an input field, the ngSubmit directive executes the expression provided to it.
The primary purpose of ngSubmit is to decouple the form submission logic from the native browser's default
To use ngSubmit, you first define a method in your component's TypeScript file that will contain the