\documentclass[10pt,a4paper]{article} % Packages \usepackage{fancyhdr} % For header and footer \usepackage{multicol} % Allows multicols in tables \usepackage{tabularx} % Intelligent column widths \usepackage{tabulary} % Used in header and footer \usepackage{hhline} % Border under tables \usepackage{graphicx} % For images \usepackage{xcolor} % For hex colours %\usepackage[utf8x]{inputenc} % For unicode character support \usepackage[T1]{fontenc} % Without this we get weird character replacements \usepackage{colortbl} % For coloured tables \usepackage{setspace} % For line height \usepackage{lastpage} % Needed for total page number \usepackage{seqsplit} % Splits long words. %\usepackage{opensans} % Can't make this work so far. Shame. Would be lovely. \usepackage[normalem]{ulem} % For underlining links % Most of the following are not required for the majority % of cheat sheets but are needed for some symbol support. \usepackage{amsmath} % Symbols \usepackage{MnSymbol} % Symbols \usepackage{wasysym} % Symbols %\usepackage[english,german,french,spanish,italian]{babel} % Languages % Document Info \author{Roman K. (Roman)} \pdfinfo{ /Title (angular-js-filters-v1-3-0.pdf) /Creator (Cheatography) /Author (Roman K. (Roman)) /Subject (Angular Js Filters (v1.3.0) Cheat Sheet) } % Lengths and widths \addtolength{\textwidth}{6cm} \addtolength{\textheight}{-1cm} \addtolength{\hoffset}{-3cm} \addtolength{\voffset}{-2cm} \setlength{\tabcolsep}{0.2cm} % Space between columns \setlength{\headsep}{-12pt} % Reduce space between header and content \setlength{\headheight}{85pt} % If less, LaTeX automatically increases it \renewcommand{\footrulewidth}{0pt} % Remove footer line \renewcommand{\headrulewidth}{0pt} % Remove header line \renewcommand{\seqinsert}{\ifmmode\allowbreak\else\-\fi} % Hyphens in seqsplit % This two commands together give roughly % the right line height in the tables \renewcommand{\arraystretch}{1.3} \onehalfspacing % Commands \newcommand{\SetRowColor}[1]{\noalign{\gdef\RowColorName{#1}}\rowcolor{\RowColorName}} % Shortcut for row colour \newcommand{\mymulticolumn}[3]{\multicolumn{#1}{>{\columncolor{\RowColorName}}#2}{#3}} % For coloured multi-cols \newcolumntype{x}[1]{>{\raggedright}p{#1}} % New column types for ragged-right paragraph columns \newcommand{\tn}{\tabularnewline} % Required as custom column type in use % Font and Colours \definecolor{HeadBackground}{HTML}{333333} \definecolor{FootBackground}{HTML}{666666} \definecolor{TextColor}{HTML}{333333} \definecolor{DarkBackground}{HTML}{A3A2A0} \definecolor{LightBackground}{HTML}{F3F3F3} \renewcommand{\familydefault}{\sfdefault} \color{TextColor} % Header and Footer \pagestyle{fancy} \fancyhead{} % Set header to blank \fancyfoot{} % Set footer to blank \fancyhead[L]{ \noindent \begin{multicols}{3} \begin{tabulary}{5.8cm}{C} \SetRowColor{DarkBackground} \vspace{-7pt} {\parbox{\dimexpr\textwidth-2\fboxsep\relax}{\noindent \hspace*{-6pt}\includegraphics[width=5.8cm]{/web/www.cheatography.com/public/images/cheatography_logo.pdf}} } \end{tabulary} \columnbreak \begin{tabulary}{11cm}{L} \vspace{-2pt}\large{\bf{\textcolor{DarkBackground}{\textrm{Angular Js Filters (v1.3.0) Cheat Sheet}}}} \\ \normalsize{by \textcolor{DarkBackground}{Roman K. (Roman)} via \textcolor{DarkBackground}{\uline{cheatography.com/19465/cs/2500/}}} \end{tabulary} \end{multicols}} \fancyfoot[L]{ \footnotesize \noindent \begin{multicols}{3} \begin{tabulary}{5.8cm}{LL} \SetRowColor{FootBackground} \mymulticolumn{2}{p{5.377cm}}{\bf\textcolor{white}{Cheatographer}} \\ \vspace{-2pt}Roman K. (Roman) \\ \uline{cheatography.com/roman} \\ \end{tabulary} \vfill \columnbreak \begin{tabulary}{5.8cm}{L} \SetRowColor{FootBackground} \mymulticolumn{1}{p{5.377cm}}{\bf\textcolor{white}{Cheat Sheet}} \\ \vspace{-2pt}Published 27th September, 2014.\\ Updated 12th May, 2016.\\ Page {\thepage} of \pageref{LastPage}. \end{tabulary} \vfill \columnbreak \begin{tabulary}{5.8cm}{L} \SetRowColor{FootBackground} \mymulticolumn{1}{p{5.377cm}}{\bf\textcolor{white}{Sponsor}} \\ \SetRowColor{white} \vspace{-5pt} %\includegraphics[width=48px,height=48px]{dave.jpeg} Measure your website readability!\\ www.readability-score.com \end{tabulary} \end{multicols}} \begin{document} \raggedright \raggedcolumns % Set font size to small. Switch to any value % from this page to resize cheat sheet text: % www.emerson.emory.edu/services/latex/latex_169.html \footnotesize % Small font. \begin{multicols*}{3} \begin{tabularx}{5.377cm}{X} \SetRowColor{DarkBackground} \mymulticolumn{1}{x{5.377cm}}{\bf\textcolor{white}{Filter Usage}} \tn % Row 0 \SetRowColor{LightBackground} \mymulticolumn{1}{x{5.377cm}}{{\bf{In HTML}}} \tn \mymulticolumn{1}{x{5.377cm}}{\hspace*{6 px}\rule{2px}{6px}\hspace*{6 px}\{\{ value | filter\_name : arg1 : arg2 \}\}} \tn % Row Count 2 (+ 2) % Row 1 \SetRowColor{white} \mymulticolumn{1}{x{5.377cm}}{{\bf{In Javascript}}} \tn \mymulticolumn{1}{x{5.377cm}}{\hspace*{6 px}\rule{2px}{6px}\hspace*{6 px}\seqsplit{\$filter('filter\_name')(value}, arg1, arg2)} \tn % Row Count 4 (+ 2) \hhline{>{\arrayrulecolor{DarkBackground}}-} \end{tabularx} \par\addvspace{1.3em} \begin{tabularx}{5.377cm}{X} \SetRowColor{DarkBackground} \mymulticolumn{1}{x{5.377cm}}{\bf\textcolor{white}{currency}} \tn % Row 0 \SetRowColor{LightBackground} \mymulticolumn{1}{x{5.377cm}}{{\bf{amount}}, {\emph{number}}} \tn \mymulticolumn{1}{x{5.377cm}}{\hspace*{6 px}\rule{2px}{6px}\hspace*{6 px}Input to filter} \tn % Row Count 2 (+ 2) % Row 1 \SetRowColor{white} \mymulticolumn{1}{x{5.377cm}}{{\bf{symbol}} (?), {\emph{string}}} \tn \mymulticolumn{1}{x{5.377cm}}{\hspace*{6 px}\rule{2px}{6px}\hspace*{6 px}Currency symbol or identifier to be displayed} \tn % Row Count 4 (+ 2) \hhline{>{\arrayrulecolor{DarkBackground}}-} \end{tabularx} \par\addvspace{1.3em} \begin{tabularx}{5.377cm}{X} \SetRowColor{DarkBackground} \mymulticolumn{1}{x{5.377cm}}{\bf\textcolor{white}{number}} \tn % Row 0 \SetRowColor{LightBackground} \mymulticolumn{1}{x{5.377cm}}{{\bf{number}}, {\emph{number | string}}} \tn \mymulticolumn{1}{x{5.377cm}}{\hspace*{6 px}\rule{2px}{6px}\hspace*{6 px}Number to format} \tn % Row Count 2 (+ 2) % Row 1 \SetRowColor{white} \mymulticolumn{1}{x{5.377cm}}{{\bf{fractionSize}} (?), {\emph{number | string}}} \tn \mymulticolumn{1}{x{5.377cm}}{\hspace*{6 px}\rule{2px}{6px}\hspace*{6 px}Number of decimal places to round the number to. If this is not provided then the fraction size is computed from the current locale's number formatting pattern. Default: 3.} \tn % Row Count 7 (+ 5) \hhline{>{\arrayrulecolor{DarkBackground}}-} \SetRowColor{LightBackground} \mymulticolumn{1}{x{5.377cm}}{Number of decimal places to round the number to.} \tn \hhline{>{\arrayrulecolor{DarkBackground}}-} \end{tabularx} \par\addvspace{1.3em} \begin{tabularx}{5.377cm}{X} \SetRowColor{DarkBackground} \mymulticolumn{1}{x{5.377cm}}{\bf\textcolor{white}{uppercase}} \tn % Row 0 \SetRowColor{LightBackground} \mymulticolumn{1}{x{5.377cm}}{{\bf{input}}, {\emph{string}}} \tn % Row Count 1 (+ 1) \hhline{>{\arrayrulecolor{DarkBackground}}-} \SetRowColor{LightBackground} \mymulticolumn{1}{x{5.377cm}}{Converts string to uppercase.} \tn \hhline{>{\arrayrulecolor{DarkBackground}}-} \end{tabularx} \par\addvspace{1.3em} \begin{tabularx}{5.377cm}{X} \SetRowColor{DarkBackground} \mymulticolumn{1}{x{5.377cm}}{\bf\textcolor{white}{lowercase}} \tn % Row 0 \SetRowColor{LightBackground} \mymulticolumn{1}{x{5.377cm}}{{\bf{input}}, {\emph{string}}} \tn % Row Count 1 (+ 1) \hhline{>{\arrayrulecolor{DarkBackground}}-} \SetRowColor{LightBackground} \mymulticolumn{1}{x{5.377cm}}{Converts string to lowercase.} \tn \hhline{>{\arrayrulecolor{DarkBackground}}-} \end{tabularx} \par\addvspace{1.3em} \begin{tabularx}{5.377cm}{X} \SetRowColor{DarkBackground} \mymulticolumn{1}{x{5.377cm}}{\bf\textcolor{white}{limitTo}} \tn % Row 0 \SetRowColor{LightBackground} \mymulticolumn{1}{x{5.377cm}}{{\bf{input}}, {\emph{Array | string}}} \tn \mymulticolumn{1}{x{5.377cm}}{\hspace*{6 px}\rule{2px}{6px}\hspace*{6 px}Source array or string to be limited.} \tn % Row Count 2 (+ 2) % Row 1 \SetRowColor{white} \mymulticolumn{1}{x{5.377cm}}{{\bf{limit}}, {\emph{string | number}}} \tn \mymulticolumn{1}{x{5.377cm}}{\hspace*{6 px}\rule{2px}{6px}\hspace*{6 px}The length of the returned array or string.} \tn % Row Count 4 (+ 2) \hhline{>{\arrayrulecolor{DarkBackground}}-} \SetRowColor{LightBackground} \mymulticolumn{1}{x{5.377cm}}{Creates a new array or string containing only a specified number of elements.} \tn \hhline{>{\arrayrulecolor{DarkBackground}}-} \end{tabularx} \par\addvspace{1.3em} \begin{tabularx}{5.377cm}{X} \SetRowColor{DarkBackground} \mymulticolumn{1}{x{5.377cm}}{\bf\textcolor{white}{date}} \tn % Row 0 \SetRowColor{LightBackground} \mymulticolumn{1}{x{5.377cm}}{{\bf{date}}, {\emph{Date | number |string}}} \tn \mymulticolumn{1}{x{5.377cm}}{\hspace*{6 px}\rule{2px}{6px}\hspace*{6 px}Date to format either as Date object, milliseconds (string or number) or various ISO 8601 datetime string formats.} \tn % Row Count 4 (+ 4) % Row 1 \SetRowColor{white} \mymulticolumn{1}{x{5.377cm}}{{\bf{format}} (?), {\emph{string}}} \tn \mymulticolumn{1}{x{5.377cm}}{\hspace*{6 px}\rule{2px}{6px}\hspace*{6 px}Formatting rules. If not specified, mediumDate is used.} \tn % Row Count 7 (+ 3) \hhline{>{\arrayrulecolor{DarkBackground}}-} \SetRowColor{LightBackground} \mymulticolumn{1}{x{5.377cm}}{Formats date to a string based on the requested format.} \tn \hhline{>{\arrayrulecolor{DarkBackground}}-} \end{tabularx} \par\addvspace{1.3em} \begin{tabularx}{5.377cm}{X} \SetRowColor{DarkBackground} \mymulticolumn{1}{x{5.377cm}}{\bf\textcolor{white}{json}} \tn % Row 0 \SetRowColor{LightBackground} \mymulticolumn{1}{x{5.377cm}}{{\bf{object}}, {\emph{*}}} \tn \mymulticolumn{1}{x{5.377cm}}{\hspace*{6 px}\rule{2px}{6px}\hspace*{6 px}Any JavaScript object (including arrays and primitive types) to filter.} \tn % Row Count 3 (+ 3) \hhline{>{\arrayrulecolor{DarkBackground}}-} \SetRowColor{LightBackground} \mymulticolumn{1}{x{5.377cm}}{Allows you to convert a JavaScript object into JSON string.} \tn \hhline{>{\arrayrulecolor{DarkBackground}}-} \end{tabularx} \par\addvspace{1.3em} \begin{tabularx}{5.377cm}{x{0.9954 cm} x{3.9816 cm} } \SetRowColor{DarkBackground} \mymulticolumn{2}{x{5.377cm}}{\bf\textcolor{white}{date: format}} \tn % Row 0 \SetRowColor{LightBackground} yyyy & 4 digit representation of year (e.g. AD 1 =\textgreater{} 0001, AD 2010 =\textgreater{} 2010) \tn % Row Count 3 (+ 3) % Row 1 \SetRowColor{white} yy & 2 digit representation of year, padded (00-99). (e.g. AD 2001 =\textgreater{} 01, AD 2010 =\textgreater{} 10) \tn % Row Count 6 (+ 3) % Row 2 \SetRowColor{LightBackground} y & 1 digit representation of year, e.g. (AD 1 =\textgreater{} 1, AD 199 =\textgreater{} 199) \tn % Row Count 8 (+ 2) % Row 3 \SetRowColor{white} MMMM & Month in year (January-December) \tn % Row Count 10 (+ 2) % Row 4 \SetRowColor{LightBackground} MMM & Month in year (Jan-Dec) \tn % Row Count 11 (+ 1) % Row 5 \SetRowColor{white} MM & Month in year, padded (01-12) \tn % Row Count 12 (+ 1) % Row 6 \SetRowColor{LightBackground} M & Month in year (1-12) \tn % Row Count 13 (+ 1) % Row 7 \SetRowColor{white} dd & Day in month, padded (01-31) \tn % Row Count 14 (+ 1) % Row 8 \SetRowColor{LightBackground} d & Day in month (1-31) \tn % Row Count 15 (+ 1) % Row 9 \SetRowColor{white} EEEE & Day in Week,(Sunday-Saturday) \tn % Row Count 16 (+ 1) % Row 10 \SetRowColor{LightBackground} EEE & Day in Week, (Sun-Sat) \tn % Row Count 17 (+ 1) % Row 11 \SetRowColor{white} HH & Hour in day, padded (00-23) \tn % Row Count 18 (+ 1) % Row 12 \SetRowColor{LightBackground} H & Hour in day (0-23) \tn % Row Count 19 (+ 1) % Row 13 \SetRowColor{white} hh & Hour in AM/PM, padded (01-12) \tn % Row Count 20 (+ 1) % Row 14 \SetRowColor{LightBackground} h & Hour in AM/PM, (1-12) \tn % Row Count 21 (+ 1) % Row 15 \SetRowColor{white} mm & Minute in hour, padded (00-59) \tn % Row Count 22 (+ 1) % Row 16 \SetRowColor{LightBackground} m & Minute in hour (0-59) \tn % Row Count 23 (+ 1) % Row 17 \SetRowColor{white} ss & Second in minute, padded (00-59) \tn % Row Count 24 (+ 1) % Row 18 \SetRowColor{LightBackground} s & Second in minute (0-59) \tn % Row Count 25 (+ 1) % Row 19 \SetRowColor{white} .sss & Millisecond in second, padded (000-999) \tn % Row Count 27 (+ 2) % Row 20 \SetRowColor{LightBackground} a & AM/PM marker \tn % Row Count 28 (+ 1) % Row 21 \SetRowColor{white} Z & 4 digit (+sign) representation of the timezone offset (-1200-+1200) \tn % Row Count 31 (+ 3) \end{tabularx} \par\addvspace{1.3em} \vfill \columnbreak \begin{tabularx}{5.377cm}{x{0.9954 cm} x{3.9816 cm} } \SetRowColor{DarkBackground} \mymulticolumn{2}{x{5.377cm}}{\bf\textcolor{white}{date: format (cont)}} \tn % Row 22 \SetRowColor{LightBackground} ww & ISO-8601 week of year (00-53) \tn % Row Count 1 (+ 1) % Row 23 \SetRowColor{white} w & ISO-8601 week of year (0-53) \tn % Row Count 2 (+ 1) % Row 24 \SetRowColor{LightBackground} medium & equivalent to 'MMM d, y h:mm:ss a' for en\_US locale \tn % Row Count 4 (+ 2) % Row 25 \SetRowColor{white} short & equivalent to 'M/d/yy h:mm a' for en\_US locale \tn % Row Count 6 (+ 2) % Row 26 \SetRowColor{LightBackground} \seqsplit{fullDate} & equivalent to 'EEEE, MMMM d, y' for en\_US locale \tn % Row Count 8 (+ 2) % Row 27 \SetRowColor{white} \seqsplit{longDate} & equivalent to 'MMMM d, y' for en\_US locale \tn % Row Count 10 (+ 2) % Row 28 \SetRowColor{LightBackground} \seqsplit{mediumDate} & equivalent to 'MMM d, y' for en\_US locale \tn % Row Count 12 (+ 2) % Row 29 \SetRowColor{white} \seqsplit{shortDate} & equivalent to 'M/d/yy' for en\_US locale \tn % Row Count 14 (+ 2) % Row 30 \SetRowColor{LightBackground} \seqsplit{mediumTime} & equivalent to 'h:mm:ss a' for en\_US locale \tn % Row Count 16 (+ 2) % Row 31 \SetRowColor{white} \seqsplit{shortTime} & equivalent to 'h:mm a' for en\_US locale \tn % Row Count 18 (+ 2) \hhline{>{\arrayrulecolor{DarkBackground}}--} \end{tabularx} \par\addvspace{1.3em} \begin{tabularx}{5.377cm}{X} \SetRowColor{DarkBackground} \mymulticolumn{1}{x{5.377cm}}{\bf\textcolor{white}{filter}} \tn % Row 0 \SetRowColor{LightBackground} \mymulticolumn{1}{x{5.377cm}}{{\bf{array}}, {\emph{Array}}} \tn \mymulticolumn{1}{x{5.377cm}}{\hspace*{6 px}\rule{2px}{6px}\hspace*{6 px}The source array.} \tn % Row Count 2 (+ 2) % Row 1 \SetRowColor{white} \mymulticolumn{1}{x{5.377cm}}{{\bf{expression}}, {\emph{string | Object | function()}}} \tn \mymulticolumn{1}{x{5.377cm}}{\hspace*{6 px}\rule{2px}{6px}\hspace*{6 px}The predicate to be used for selecting items from array.} \tn % Row Count 6 (+ 4) % Row 2 \SetRowColor{LightBackground} \mymulticolumn{1}{x{5.377cm}}{{\bf{comparator}}, {\emph{function(actual, expected) | true | undefined}}} \tn \mymulticolumn{1}{x{5.377cm}}{\hspace*{6 px}\rule{2px}{6px}\hspace*{6 px}Comparator which is used in determining if the expected value (from the filter expression) and actual value (from the object in the array) should be considered a match.} \tn % Row Count 12 (+ 6) \hhline{>{\arrayrulecolor{DarkBackground}}-} \SetRowColor{LightBackground} \mymulticolumn{1}{x{5.377cm}}{Selects a subset of items from array and returns it as a new array.} \tn \hhline{>{\arrayrulecolor{DarkBackground}}-} \end{tabularx} \par\addvspace{1.3em} \begin{tabularx}{5.377cm}{X} \SetRowColor{DarkBackground} \mymulticolumn{1}{x{5.377cm}}{\bf\textcolor{white}{filter: expression}} \tn % Row 0 \SetRowColor{LightBackground} \mymulticolumn{1}{x{5.377cm}}{{\bf{Expression}} — the predicate to be used for selecting items from {\emph{array}}.} \tn % Row Count 2 (+ 2) % Row 1 \SetRowColor{white} \mymulticolumn{1}{x{5.377cm}}{string} \tn \mymulticolumn{1}{x{5.377cm}}{\hspace*{6 px}\rule{2px}{6px}\hspace*{6 px}The string is evaluated as an expression and the resulting value is used for substring match against the contents of the {\emph{array}}. All strings or objects with string properties in array that contain this string will be returned. The predicate can be negated by prefixing the string with !.} \tn % Row Count 10 (+ 8) % Row 2 \SetRowColor{LightBackground} \mymulticolumn{1}{x{5.377cm}}{Object} \tn \mymulticolumn{1}{x{5.377cm}}{\hspace*{6 px}\rule{2px}{6px}\hspace*{6 px}A pattern object can be used to filter specific properties on objects contained by {\emph{array}}. A special property name \$ can be used (as in \{\$:"text"\}) to accept a match against any property of the object. That's equivalent to the simple substring match with a string as described above.} \tn % Row Count 18 (+ 8) % Row 3 \SetRowColor{white} \mymulticolumn{1}{x{5.377cm}}{function(value, index)} \tn \mymulticolumn{1}{x{5.377cm}}{\hspace*{6 px}\rule{2px}{6px}\hspace*{6 px}A predicate function can be used to write arbitrary filters. The function is called for each element of {\emph{array}}. The final result is an array of those elements that the predicate returned true for.} \tn % Row Count 24 (+ 6) \hhline{>{\arrayrulecolor{DarkBackground}}-} \end{tabularx} \par\addvspace{1.3em} \begin{tabularx}{5.377cm}{X} \SetRowColor{DarkBackground} \mymulticolumn{1}{x{5.377cm}}{\bf\textcolor{white}{orderBy}} \tn % Row 0 \SetRowColor{LightBackground} \mymulticolumn{1}{x{5.377cm}}{{\bf{array}}, {\emph{Array}}} \tn \mymulticolumn{1}{x{5.377cm}}{\hspace*{6 px}\rule{2px}{6px}\hspace*{6 px}The array to sort.} \tn % Row Count 2 (+ 2) % Row 1 \SetRowColor{white} \mymulticolumn{1}{x{5.377cm}}{{\bf{expression}}, {\emph{function(}}) | string | Array.(function({\emph{)|string)\textgreater{}}}} \tn \mymulticolumn{1}{x{5.377cm}}{\hspace*{6 px}\rule{2px}{6px}\hspace*{6 px}A predicate to be used by the comparator to determine the order of elements.} \tn % Row Count 6 (+ 4) % Row 2 \SetRowColor{LightBackground} \mymulticolumn{1}{x{5.377cm}}{{\bf{reverse}} (?), {\emph{boolean}}} \tn \mymulticolumn{1}{x{5.377cm}}{\hspace*{6 px}\rule{2px}{6px}\hspace*{6 px}reverse the order of the array.} \tn % Row Count 8 (+ 2) \hhline{>{\arrayrulecolor{DarkBackground}}-} \SetRowColor{LightBackground} \mymulticolumn{1}{x{5.377cm}}{Orders a specified array by the expression predicate. It is ordered alphabetically for strings and numerically for numbers.} \tn \hhline{>{\arrayrulecolor{DarkBackground}}-} \end{tabularx} \par\addvspace{1.3em} \begin{tabularx}{5.377cm}{X} \SetRowColor{DarkBackground} \mymulticolumn{1}{x{5.377cm}}{\bf\textcolor{white}{orderBy: expression}} \tn % Row 0 \SetRowColor{LightBackground} \mymulticolumn{1}{x{5.377cm}}{A predicate to be used by the comparator to determine the order of elements.} \tn % Row Count 2 (+ 2) % Row 1 \SetRowColor{white} \mymulticolumn{1}{x{5.377cm}}{function} \tn \mymulticolumn{1}{x{5.377cm}}{\hspace*{6 px}\rule{2px}{6px}\hspace*{6 px}Getter function. The result of this function will be sorted using the \textless{}, =, \textgreater{} operator.} \tn % Row Count 5 (+ 3) % Row 2 \SetRowColor{LightBackground} \mymulticolumn{1}{x{5.377cm}}{string} \tn \mymulticolumn{1}{x{5.377cm}}{\hspace*{6 px}\rule{2px}{6px}\hspace*{6 px}An Angular expression. The result of this expression is used to compare elements (for example name to sort by a property called name or name.substr(0, 3) to sort by 3 first characters of a property called name). The result of a constant expression is interpreted as a property name to be used in comparisons (for example "special name" to sort object by the value of their special name property). An expression can be optionally prefixed with + or - to control ascending or descending sort order (for example, +name or -name). If no property is provided, (e.g. '+') then the array element itself is used to compare where sorting.} \tn % Row Count 20 (+ 15) % Row 3 \SetRowColor{white} \mymulticolumn{1}{x{5.377cm}}{Array} \tn \mymulticolumn{1}{x{5.377cm}}{\hspace*{6 px}\rule{2px}{6px}\hspace*{6 px}An array of function or string predicates. The first predicate in the array is used for sorting, but when two items are equivalent, the next predicate is used.} \tn % Row Count 25 (+ 5) % Row 4 \SetRowColor{LightBackground} \mymulticolumn{1}{x{5.377cm}}{f the predicate is missing or empty then it defaults to '+'.} \tn % Row Count 27 (+ 2) \hhline{>{\arrayrulecolor{DarkBackground}}-} \end{tabularx} \par\addvspace{1.3em} % That's all folks \end{multicols*} \end{document}