Routing in angular application is used for selecting different views on the client side.In a normal web application when we click on any hyper link on a page ,this results in a new request to the web server.Web server returns HTTP response to the browser.So every request for a new view or page is a separate HTTP […]
AngularJS
Use and example of ngClass in AngularJS
ngClass directive let us add the CSS class at run time.We will understand this by use and example of ngClass in AngularJS.This is useful in many scenarios: Suppose we want to add a particular class when a control is disabled and other CSS class when the control is enabled the we can use boolean expression with […]
ng-include directive in AngularJS
ng-include directive in AngularJS is used to include html content from another file.It is useful when we want to split the html in multiple files.There can be multiple reasons of placing html in different files: To split a complex UI into simpler html pages To display html conditionally To use ng-include use it as: <element ng-include=”file” […]
Routing in AngularJS
Navigation is one of the most important aspects of any web application.Navigation means loading different UI based on user input and selection.Routing in AngularJS means selecting different views depending on the browser URL. Application consists of different UI elements defined in different views.To change the view displayed to the user routing is used.Routing in AngularJS […]
@Input and @Output decorators in Angular 2
Angular 2 application consists of a collection of components.Components in Angular 2 application need to interact with other components in the application. Angular 2 provides two useful property decorators for interaction between components. Input and Output decorators are used to pass data into and out of the component.We attach the decorators to the component properties. […]