Categories: AngularJs

Global API – AngularJS

AngularJS global API provides some set of functions that can be invoked by using angulr object.

angular.isString()
angular.isNumber()
angular.lowercase()
angular.uppercase()

angular.isString() – It is used to check if something is string or not. Returns true or false.
angular.isNumber() – It is used to check if something is numeric or not. Returns true or false.

[html]
State name: {{state}}
Is numeric: {{state1}}
Is string: {{state2}}


[/html]

angular.lowercase() – It is used to convert string to lower case.
angular.uppercase() – It is used to convert string to uppercase.

[html]
Display state name: {{state}}
Display state name: {{state2}}


[/html]

Including Files in angularJS:

ng-include directive is used to include the files.

[html]

[/html]

jeff77

Disqus Comments Loading...

Recent Posts

Noun

A Noun is the name of a person, place or thing. or Name of anything is noun. For example: Sita…

10 years ago

Introduction – AngularJS

Misko Hevery, a Google employee, developed AngularJS. First version 1.0 of AngularJS was released in 2012. Now AngularJS is fully…

9 years ago

Expressions – AngularJS

AngularJS expressions contain operators,literals, and variables.  AngularJS expressions can be written inside HTML while JavaScript expressions can't be.  AngularJS expressions…

9 years ago

Noun – Exercise

Some sentences are given below. Choose the nouns and mention the type of noun whether they are proper noun, common…

9 years ago

Modules – AngularJS

Modules are containers for appication controller. They contain different parts of an application. [html] {{ state + " " +…

9 years ago

Directives – AngularJS

Using Directives you can extend HTML attributes. In AngularJS you can define your own directives while it has its own…

9 years ago