Angular 2 interview questions and answer
In this post we will look at Angular2 questions. Examples are provided with explanation.
- What are the new features of Angular2?
- Angular 2 is written entirely in Typescript and meets the ECMAScript 6 specification.
- Component-Based- Angular 2 is entirely component based. Controllers and $scope are no longer used. They have been replaced by components and directives.
- Directives- The specification for directives is considerably simplified, although they are still subject to change. With the @Directive annotation, a directive can be declared.
- Dependency Injection- Because of the improved dependency injection model in Angular2 there are more opportunities for component / object-based work.
- Use of TypeScript-TypeScript is a typed super set of JavaScript which has been built and maintained by Microsoft and chosen by the AngularJS team for development. The presence of types makes the code written in TypeScript less prone to run-time errors. In recent times, the support for ES6 has been greatly improved and a few features from ES7 have been added as well.
- Generics- TypeScript has generics which can be used in the frontend.
- Lambdas with TypeScript- In TypeScript, lambdas are available.
- Forms and Validations- Forms and validations are an important aspect of frontend development. Within Angular 2 the Form Builder and Control Group are defined.
- What is the need of Angular2?
Angular 2 is not just a typical upgrade but a totally new development. The whole framework is rewritten from the ground. Angular 2 got rid of many things like $scope, controllers, DDO, jqLite, angular.module etc. It uses components for almost everything. Imagine that even the whole app is now a component. Also it takes advantage of ES6 / TypeScript syntax. Developing Angular 2 apps in TypeScript has made it even more powerful. . Apart from that, many things have evolved and re-designed like the template engine and many more.
Casino - Dr. MJD
ReplyDeleteA complete and comprehensive 창원 출장안마 guide to Las Vegas casinos. You'll discover what slot machines and 제주도 출장샵 video 광주광역 출장마사지 poker rooms 여수 출장샵 were, plus 의정부 출장안마 the casinos Jan 8, 2020 · Uploaded by Las Vegas, NV