Like any other scripting language AngulatJS also has its own built in functions. These built in functions could be very usefull when you require to display text in upper case or display text in lower case or check if variable contains string value. Sometimes you may need to chack if current object is function or is number or is date or is array.
When you work with json data you may require to check if the object is json or convert javascript object to JSON, convert json data into javascript object. In order to use AngularJS functions, you need to understand each AngularJS built in function in details given below.
Here is a list of built-in functions with description.
Function | Description |
---|---|
lowercase | This function is intended to converts the specified string to lowercase. |
uppercase | This function is intended to converts the specified string to uppercase. |
forEach | This function is intended to iterator the each items in array. |
extend | This function is intended to extend the destination object by copying the enumerable properties of object ie. var obj = angular.extend({}, obj1, obj2). |
merge | This function is intended to deeply extend the destination object by copying the enumerable properties of object ie. var obj = angular.merge({}, obj1, obj2). |
noop | This function performs no operations, can be useful when writing code in the functional style. |
identity | This function returns its first argument, can be useful when writing code in the functional style. |
isUndefined | This function is intended to identify if a reference is undefined. |
isDefined | This function is intended to identify if a reference is defined. |
isObject | This function is intended to identify if a reference is object, nulls are not considered to be objects. |
isString | This function is intended to identify if a reference is string. |
isNumber | This function is intended to identify if a reference is number. |
isDate | This function is intended to identify if a value is date. |
isArray | This function is intended to identify if a reference is array. |
isFunction | This function is intended to identify if a reference is function. |
isElement | This function is intended to identify if a reference is DOM element. |
copy | This function is intended to creates a deep copy of source object or an array. |
equals | This function is intended to identify two objects or two values are equivalent, it supports value types, regular expressions, arrays and objects. |
bind | Allows to work with partial functions. |
toJson | This function is intended to serializes input into a JSON-formatted string. |
fromJson | This function is intended to deserializes a JSON string. |
bootstrap | This function is intended to manually start up angular application. |
reloadWithDebugInfo | This function is intended to reload the current application with debug information turned on. |
injector | This function is intended to creates an injector object that can be used for retrieving services as well as for dependency injection. |
element | This function is intended to wraps a raw DOM element or HTML string as a jQuery element. |
module | This function is a global place for creating, registering and retrieving Angular modules. |
In order to understand each filter, click on any filter listed in the above table.