Product
Introducing SSO
Streamline your login process and enhance security by enabling Single Sign-On (SSO) on the Socket platform, now available for all customers on the Enterprise plan, supporting 20+ identity providers.
The only web typograph that don't make a mess out of your text. Russian and English supported.
Readme
Richtypo assumes that your text already has right dashes and quotes. The main concern is to add non-breaking spaces to the right places.
This project is heavily inspired by Artem Sapegin's richtypo.
pip install richtypo
from richtypo import Richtypo
r = Richtypo(ruleset='ru-lite')
well_done = r.richtypo(text)
from richtypo.filter import filter
env = jinja2.Environment(
filters={
'richtypo': filter
}
)
Template:
{{ text | richtypo('ru-lite') }}
# your_app/templatetags/richtypo.py
from django import template
from django.template.defaultfilters import stringfilter
from django.utils.safestring import mark_safe
from richtypo.filter import filter as typograph
register = template.Library()
@register.filter
@stringfilter
def richtypo(value, ruleset='generic'):
return mark_safe(typograph(value, ruleset))
Template:
{% load richtypo %}
{{ object.text | richtypo:"ru-lite"}}
MIT
FAQs
The only web typograph that don't make a mess out of your text. Russian and English supported.
We found that richtypo demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?
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.
Product
Streamline your login process and enhance security by enabling Single Sign-On (SSO) on the Socket platform, now available for all customers on the Enterprise plan, supporting 20+ identity providers.
Security News
Tea.xyz, a crypto project aimed at rewarding open source contributions, is once again facing backlash due to an influx of spam packages flooding public package registries.
Security News
As cyber threats become more autonomous, AI-powered defenses are crucial for businesses to stay ahead of attackers who can exploit software vulnerabilities at scale.