Join the social network of Tech Nerds, increase skill rank, get work, manage projects...
  • AngularJs Filter

    • 0
    • 0
    • 0
    • 0
    • 0
    • 0
    • 0
    • 0
    • 258
    Comment on it

    When we want to format data in angularJS then we use filter.There are n number of filter available in angularJS which is used to transform data. AngularJS filter are:

    1) Currency: Which will format a number to a currency format.
    2) date:Which will format a date to a specified format.
    3) filter:Select a subset of items from an array.
    4) lowercase:Format a string to lower case.
    5) uppercase:Format a string to upper case.



    <!DOCTYPE html>
    <script src=""></script>
    <div ng-app="myAppFilter" ng-controller="personCtrl">
    <p>My name is {{ lastName | uppercase }}</p>
    angular.module('myAppFilter', []).controller('personCtrl', function($scope) {
        $scope.firstName = "Ankit",
        $scope.lastName = "Bhatia"


    Here In the example we can see ng-app is a directives where we can define our application name and we have implement uppercase filter in the above example.

 0 Comment(s)

Sign In

Sign up using

Forgot Password
Fill out the form below and instructions to reset your password will be emailed to you:
Reset Password
Fill out the form below and reset your password: