Training
Bootcamp
Courses
Tech Sessions
Resources
Blog
Tips
GitHub
YouTube
Newsletter
Playgrounds
Pricing
Sign In
Become Member
Jinja2 Renderer
Validate and test the rendering of your Jinja templates
Tools
J2 Renderer
TTP Parser
TextFSM Parser
XPath Tester
Members Only
JMESPath Validator
JSON Schema Validator
Data Format Converter
Help Us Improve
Jinja Template
{% set string_without_last_char = input_string[:-1] %} {% set last_char_of_string = input_string[-1] -%} string_without_last_char = {{ string_without_last_char }} last_char_of_string = {{ last_char_of_string }} {% set port_channel_id = input_string | replace("PortChannel","") %} Port-Channel ID is {{ port_channel_id }}
Jinja Data
input_string: PortChannel1
Result
string_without_last_char = PortChannel last_char_of_string = 1 Port-Channel ID is 1
Show whitespace
Trim blocks
Lstrip blocks
Render
Share
Auto-Sync