Filters are used as modifier of value, that is passed into attribute directive. Could be useful e.g. for checking, if result list is empty or text equals specific value.
since 0.0.1
Stands for "and". Returns boolean.
<span ajsf-hide="hide | and userAllows">Hidden, user allows that</span>
since 0.0.1
If result is not true, then it returns value.
<span ajsf-text="!true | else 'No way'">Displays 'No way'</span>
since 0.0.1
Stands for "equals". Returns boolean.
<span ajsf-hide="list.length | eq 0">No data to be displayed</span>
since 0.0.1
Filters array for values as object or string.
<div ajsf-repeat="list | filter filterObject"></div>
since 0.0.1
Stands for "greater than". Returns boolean.
<span ajsf-hide="list.length | gt 0">No data to be displayed</span>
since 0.0.1
Stands for "greater than or equals". Returns boolean.
<span ajsf-hide="value | gte 0">Value is positive</span>
since 0.0.1
Limits result, usefull for limiting result list.
<div ajsf-repeat="data | limit limitValue">
<span ajsf-bind="item"></span>
</div>
since 0.0.1
Stands for "lower than". Returns boolean.
<span ajsf-show="list.length | lt 1">No data to be displayed</span>
since 0.0.1
Stands for "lower than or equals". Returns boolean.
<span ajsf-show="value | lt -1">Value is negative</span>
since 0.0.1
Stands for "not equals". Returns boolean.
<span ajsf-show="value | ne 'staticValue'">Value is not expected</span>
since 0.0.1
Stands for "or". Returns boolean.
<span ajsf-hide="hide | or userAllowsHide">Hidden, or user allows to hide that</span>
since 0.0.1
Sets prefix to defined value
<span ajsf-hide="data | prefix 'Speed: '"></span>
since 0.0.1
Sets suffix to defined value
<span ajsf-hide="data | suffix ' per second'"></span>
since 0.0.1
If result is true, then it returns value.
<span ajsf-text="true | then 'Yeah!'">Displays 'Yeah!'</span>
Previous chapter: 02. Built-in Attribute Directives
Next chapter: 04. Custom Attribute Directives