AngularJS Function Components :
We focus ng function components. It will support to do a set of basic task to done. This component to manipulate into all set of function to all angular components. Like will do a list of functions
angular.lowercase - This function will converted string into lowercase.
angular.uppercase - This function will converted string into uppercase.
angular.isNumber - Determinate whether a number variable into find.
angular.isString - Determinate whether a string variable into find.
angular.isArray - Determinate whether a array variable into find.
angular.isObject - Determinate whether a Object variable into find.
The above List have some basic will refer more into angularjs.
HTML Code:
<div ng-app="isApp">
<div ng-controller="isCtrl">
Cos value is {{cos}} <br>
{{firstString}} <br>
Sin value is {{sin}}<br>
{{secondString}}
</div>
</div>
JavaScript Code:
var app = angular.module('isApp',[]);
app.controller('isCtrl', function($scope){
$scope.cos = 4500;
$scope.sin = "4500";
$scope.firstString = 'Cos value is a number -> '+ angular.isNumber($scope.cos);
$scope.secondString = 'Sin value is a number -> '+angular.isNumber($scope.sin);
});
Comments
Post a Comment