Template SyntaxText and DirectivesTemplate parserParse errorsCaching templatesFlexible syntaxTemplate TagsInterpolated VariablesCommentsWhitespace ChompingChomping flagsChomping optionsChomping constantsMultiple Directive TagsSide-Effect NotationCapturing Directive OutputTemplate FilenamesTemplate VariablesWhat’s in a Name?Simple Data TypesComplex Data TypesListsHashesDot OperatorCompound dot operationsInterpolated variables namesPrivate variablesDynamic Data TypesSubroutinesObjectsPassing argumentsPointless argumentsNamed parametersMixing dynamic and static dataReturning valuesError handlingSpecial Variablestemplatecomponentlooperrorcontentglobalview, itemVariable ScopeCompile-Time Constant FoldingVirtual MethodsScalar Virtual Methodschunk(size)definedhashlengthlistmatch(pattern)repeat(n)replace(search, replace)sizesplit(pattern)List Virtual Methodsfirst(n)grep(pattern)join(delimiter)last(n)maxmerge(list)popreverseshiftsizeslice(from, to)sort, nsortsplice(offset, length, list)uniqueunshift(item)push(item)Hash Virtual Methodsdefined(key)eachexists(key)import(hash)item(key)keyslistsizesort, nsortvaluesDefining New Virtual MethodsStash package variablesStash and context methods