Angular Js is the most widely used web development framework which can be used potentially for mobile apps and desktop applications development. Especially it can be used for Hybrid (Cross Platform) mobile application development. It is developed by the Google developer team. Day by day it’s updating its version. 1,2,4,5,6.. on going.
Here you can get all type of questions which is frequently asked by Top MNC. Make sure before going to interview just brush up it once.
What Is AngularJS 5?
Its an advanced version of angular 4 which have some modified features.
Angular Team keeps trying to update this angular js. Angular 5 is released on Oct 2017.
It a nothing but a typescript library which makes specially develop mobile apps and desktop applications.
What are the additional features in angular js 5
2. Compiler Improvements( Make AOT the default )
3. Angular Universal State Transfer
4. New Router Lifecycle Events
6. Improvement on XSRF Protection
7. Remove *.ngfactory.ts files
8. Type checking in templates
How to update httpclient in Angular js 5?
You update the HTTPClient in 3 easy steps:
1. Replace HttpModule with Http Client Module from @angular/common/http.
2. Inject the HttpClient service
3. Remove any map(res =>res.json()) calls, which are not required anymore.
What is the Built Optimizer in Angular js 5 ?
Objective of Built Optimizer is to reduce size of the bundle to make better performance.
Its make smaller size of typescript file as well.
How Preserve Whitespace in Angular 5?
In the previous version there is no restriction for whitespace, tabs while creating a build, It comes unnecessarily. In angular 5 has the restrictions. just have a look below examples
Example: If you want to restrict from homepage component, then.
If you want to restrict from globally throughout the application then need to set piece of code in config.json file.
What is the life cycle event in angular 5?
In angular 5 updated 4 kinds of the event for Guards and Resolve.
2) Guards checked,
3) ResolveStart and
What are the performance level updations in angular 5?
1. It uses addEventListener for faster rendering.
2. Remove decorator DSL
3. Switch Angular to use Static-Injector instead of Reflective-Injector
4. Improvements on Lazy loading for Angular.
5. Improved Universal & AppShell Support in the CLI
6. UpdateOn Blur / Submit
What is i18N Pipes in Angular 5?
The i18n pipes that set of built-in functionality makes internationalization or changes based on the location of the date, number, currency. etc.
What is AOT in angular 5?
What is Just-in-Time (JIT) in angular 5?
Why Compile with AOT is better in angular 5?
- Faster rendering
- Fewer asynchronous requests
- Smaller Angular framework download size
- Detect template errors earlier
- Better security
What are the security principle should be implemented at the time of app building in angular 5?
1. Never use directly DOM APIs.
2. Enable Content Security Policy (CSP)
3. Preventing CSRF or XSRF attacks.
4. Use DOM Sanitizer.
5. Use the offline template compiler