Angular 12.2 is here…😎
Angular 12.2.0 is out with few new features 👏.
Let’s discuss what we have got in this new release👇.
Faster ng build🚀
The CLI now uses esbuild to optimize the built code, in combination with terser. The CLI also uses esbuild to optimize the CSS of component stylesheets.
Check split two way binding
The new error message for a banana-in-a-box binding with the output not declared should be "The output {outputName} for the two way binding is not declared.”
New APIs in Forms
Forms are added with the hasValidator, addValidators, and removeValidators methods. They allow to add and remove a validator or an array of validators to/from a form control, array or group.
These methods have a version for asynchronous validators with hasAsyncValidator, addAsyncValidators and removeAsyncValidators.
Also allows minLength/maxLength validator to be bound to null .
Language Service Updates
The native TS language service has the ability to provide autocompletions for
string literal union types. This update is for Angular to do the same in templates.
v12.2 includes better template autocomplete support for:
-string literals
- number literals
- boolean and undefined values
Router
In v12.2 it is possible to provide a RouteReuseStrategy via DI for the RouterTestingModule. It’s not possible before,only imperative instantiation.
What are you waiting for..#ngUpdate to 12.2 now😎