Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

jinja2-strcase

Package Overview
Dependencies
Maintainers
1
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

jinja2-strcase

A python package for converting string case in jinja2 templates

  • 0.0.2
  • PyPI
  • Socket score

Maintainers
1

jinja2-strcase

A python package for converting string case in jinja2 templates (including cookiecutter).

It is a port of the go package strcase

Installation

jinja2-strcase is available for download from PyPI via pip:

$ pip install jinja2-strcase

Example

from jinja2 import Environment

env = Environment(extensions=['jinja2_strcase.StrcaseExtension'])

# This will convert 'Any kind of string' -> 'any_kind_of_string'
template = env.from_string("{% 'Any kind of string' |  to_snake }")

template.render()
FunctionResult
to_snakeany_kind_of_string
to_screaming_snakeANY_KIND_OF_STRING
to_kebabany-kind-of-string
to_screaming_kebabANY-KIND-OF-STRING
to_camelAnyKindOfString
to_lower_camelanyKindOfString

Keywords

FAQs


Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc