Claude Code Plugins

Community-maintained marketplace

Feedback

jinja2-templating

@benchflow-ai/skillsbench
17
0

Generate documents from templates. Use for dynamic HTML, reports, emails, or any templated output.

Install Skill

1Download skill
2Enable skills in Claude

Open claude.ai/settings/capabilities and find the "Skills" section

3Upload to Claude

Click "Upload skill" and select the downloaded ZIP file

Note: Please verify skill by going through its instructions before using it.

SKILL.md

name jinja2-templating
description Generate documents from templates. Use for dynamic HTML, reports, emails, or any templated output.

Jinja2 Templating

Generate dynamic content from templates.

Quick Start

from jinja2 import Template

template = Template("Hello, {{ name }}!")
output = template.render(name="World")
print(output)  # "Hello, World!"

Common Patterns

Load templates from files

from jinja2 import Environment, FileSystemLoader

env = Environment(loader=FileSystemLoader("templates"))
template = env.get_template("report.html")
output = template.render(title="Report", items=data)

Loops and conditionals

{% for item in items %}
  <li>{{ item.name }}: ${{ item.price }}</li>
{% endfor %}

{% if user.is_admin %}
  <span>Admin</span>
{% else %}
  <span>User</span>
{% endif %}

Filters

{{ name | upper }}
{{ price | round(2) }}
{{ items | length }}
{{ date | default("N/A") }}

Template inheritance

{# base.html #}
<html>
<body>{% block content %}{% endblock %}</body>
</html>

{# page.html #}
{% extends "base.html" %}
{% block content %}
  <h1>{{ title }}</h1>
{% endblock %}

Custom filters

def format_currency(value):
    return f"${value:,.2f}"

env.filters["currency"] = format_currency
# {{ amount | currency }}