Detect URL, Email, Hashtag and Mention from plain-text and convert into HTML hyperlink.
Project description
linkable-py
Detect URL, Email, Hashtag and Mention from plain-text and convert into HTML hyperlink.
Install
$ pip install linkable
Usage
Basic:
from linkable import Linkable
text = 'This is test with a #hashtag from @linkable on github.com'
print(Linkable(text))
Output:
This is test with <a href="/hashtag/#hashtag">#hashtag</a> from <a href="/@linkable">@linkable</a> on <a href="http://github.com">github.com</a>
Links list:
from linkable import LinkableList
text = 'This is test with a #hashtag from @linkable on github.com'
print(LinkableList(text).links)
Output:
['#hashtag', '@linkable', 'github.com']
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
linkable-0.2.2.tar.gz
(12.0 kB
view details)
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
linkable-0.2.2-py3-none-any.whl
(12.8 kB
view details)
File details
Details for the file linkable-0.2.2.tar.gz.
File metadata
- Download URL: linkable-0.2.2.tar.gz
- Upload date:
- Size: 12.0 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/1.13.0 pkginfo/1.5.0.1 requests/2.21.0 setuptools/40.8.0 requests-toolbelt/0.9.1 tqdm/4.32.1 CPython/3.7.3
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
3f5ee63a10f2c0d4d32c29ff2c951d36b8cdac40f4b21fad223628e1fdbfce65
|
|
| MD5 |
3e7432cc8858c6c3436efea6841808af
|
|
| BLAKE2b-256 |
f68078e2c202e5f6fef5f85ce5fa65f9bb75e5768107611495a4d0baa7ce7786
|
File details
Details for the file linkable-0.2.2-py3-none-any.whl.
File metadata
- Download URL: linkable-0.2.2-py3-none-any.whl
- Upload date:
- Size: 12.8 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/1.13.0 pkginfo/1.5.0.1 requests/2.21.0 setuptools/40.8.0 requests-toolbelt/0.9.1 tqdm/4.32.1 CPython/3.7.3
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
86454edb32a9b892752b1934acaad78f854a58deedee13fb8ef8cdd1abde451b
|
|
| MD5 |
53d51d6da03eb182e8d94a4b543232e0
|
|
| BLAKE2b-256 |
dc82a9f0e11f8f4f872dd5b38a6f4e9fd22bb1fcb7bf7841bba60f03e58116a8
|