Forms

Typically in Single Page Frameworks (SPA) such as Angular, forms are not used to automatically submit data to the server, because input fields are bound to properties of JavaScript objects that are sent in JSON format to the server through AJAX operations. However, forms still remain useful for the functionalities listed in the following points 1 and 2. Input fields are validated in the context of all other input fields contained in the same form, and further processing of the form data may proceed only if the form is valid, that is, if all input fields contained in the form are valid.

HTML forms have three connected purposes: 

  1. Grouping input fields that contribute to the same update operation.
  2. Providing a context for validation. ...

Get Hands-On TypeScript for C# and .NET Core Developers now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.