williambelle / elide-text

A very simple text truncating function.

Home Page:https://pypi.org/project/elide-text/

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

elide-text

Build Status Coverage Status Requirements Status PyPI version

A very simple text truncating function.

Install

pip install elide-text

Usage

from elidetext import elide_text

text = elide_text("A brand new tool devoted to complex neuron models", 25)
print(text) #=> A brand new tool devotedโ€ฆ

text = elide_text("๐Ÿบ๐Ÿ“ฐ๐Ÿ“š๐Ÿฎ๐ŸŒต๐Ÿ“ด๐ŸŽฏ๐ŸŒฟ๐Ÿ‘‚๐Ÿ‘“๐Ÿ‘Œ", 6)
print(text) #=> ๐Ÿบ๐Ÿ“ฐ๐Ÿ“š๐Ÿฎ๐ŸŒตโ€ฆ

Contributing

Contributions are always welcome.

See Contributing.

Developer

License

The MIT License (MIT)

About

A very simple text truncating function.

https://pypi.org/project/elide-text/

License:MIT License


Languages

Language:Python 100.0%