Afratafreeh Doc Tutorial- -

| Filter | Input | Output | |--------|-------|--------| | upper | name → "john" | "JOHN" | | capitalize | city → "paris" | "Paris" | | default('N/A') | middle_name (null) | "N/A" | | number_format(2) | 1234.5 | "1,234.50" |

Use the --debug flag to print the abstract syntax tree (AST) before rendering. Afratafreeh Doc Tutorial-

Whether you are a backend developer integrating report generation, an admin managing legal paperwork, or a data scientist exporting analytics, this tutorial will walk you through every command, configuration, and best practice for mastering Afratafreeh Doc. | Filter | Input | Output | |--------|-------|--------|

afratafreeh render -t problem.afd -d data.json --debug Use Case 1: Automated Legal Contracts Problem: A law firm needs to generate NDAs for 50 different counterparties. Solution: Create a master nda_template.afd with placeholders ( party_a , effective_date ). Use a CSV loop and the batch command. Use Case 2: E-commerce Order Summaries Problem: Send a styled HTML receipt via email plus a PDF attachment. Solution: Generate once, output to both formats: Solution: Create a master nda_template

<table border="1"> <tr><th>Product</th><th>Price</th></tr> % for product in cart.products % <tr> <td> product.name </td> <td>$ product.price </td> </tr> % endfor % </table> Break down large documents.

"user": "name": "Alex Johnson" Run the command:

afratafreeh render -t template.afd -d data.json -o output.pdf You should see output.pdf with the dynamic name and today's date. Chapter 3: The Afratafreeh Syntax Deep Dive This section is your cheatsheet. The language is a mixture of Jinja2 and JavaScript expressions. Variables & Filters Modify output using the pipe | operator.