Where Learning is Pleasure

Jayaram Krishnaswamy

Subscribe to Jayaram Krishnaswamy: eMailAlertsEmail Alerts
Get Jayaram Krishnaswamy: homepageHomepage mobileMobile rssRSS facebookFacebook twitterTwitter linkedinLinkedIn


Blog Feed Post

Using AngularJS on the localhost

AngularJS directives are extensions of HTML markups. They are one of several components of AngularJS. Directives can be attributes, element names, CSS class etc.

AngularJS script reference is important and the script can be found here:

https://ajax.googleapis.com/ajax/libs/angularjs/1.2.25/angular.min.js"
The above script reference needs to be added to your hTML page.

You can find the whole list of directives here:
https://docs.angularjs.org/api

Here is the usage of some directives placed in a html page that can be displayed on your localhost (in this case the IIS in Windows 10). Place this code with a suitable name in the inetpub / wwwroot directory.

======================


  Some directives in AngularJS

ng-app
Sorry, blogger still does not support the "pre" tag!
==============
When viewed on the browser (in this case Microsoft Edge), the HTML page renders as shown.


Do the following on this interactive page:
  • Type anything it gets copied next to Hello
  • Enter the increment region with your mouse, the count (presently 1) gets incremented
  • Click the link and you get to the page
Directives used in the page above and their description:
ng-app: initializes an AngularJS application
ng-model: binds the value of HTML controls (input, select, textarea) to application data
ng-init: initializes application data
ng-mouseenter: an AngularJS mouse event as a cursor moves over an dom element
ng-href: supported by the "a" tag and should be used when AngularJS code as in the example


Read the original blog entry...

More Stories By Jayaram Krishnaswamy

Jayaram Krishnaswamy is a technical writer, mostly writing articles that are related to the web and databases. He is the author of SQL Server Integration Services published by Packt Publishers in the UK. His book, 'Learn SQL Server Reporting Services 2008' was also published by Packt Publishers Inc, Birmingham. 3. "Microsoft SQL Azure Enterprise Application Development" (Dec 2010) was published by Packt Publishing Inc. 4. "Microsoft Visual Studio LightSwitch Business Application Development [Paperback] "(2011) was published by Packt Publishing Inc. 5. "Learning SQL Server Reporting Services 2012 [Paperback]" (June 2013) was Published by Packt Publishing Inc. Visit his blogs at: http://hodentek.blogspot.com http://hodentekHelp.blogspot.com http://hodnetekMSSS.blogspot.com http://hodnetekMobile.blogspot.com He writes articles on several topics to many sites.