python-hyper / hyperlink

🔗 Immutable, Pythonic, correct URLs.
https://hyperlink.readthedocs.io/
Other
283 stars 41 forks source link

RFC2397 Data URIs #41

Open mahmoud opened 6 years ago

mahmoud commented 6 years ago

Percent-encoding isn't limited by utf-8 or any other underlying encoding, and thus can represent pretty much any data. RFC2397 takes advantage of this to jam whatever data you want, along with a mimetype into a URL.

If usage is common enough, the implementation doesn't overcomplicate, I think this might make sense for a built-in hyperlink feature. The first step is definitely to research how broadly this is used.

mahmoud commented 6 years ago

https://github.com/EclecticIQ/python-data-uri is a good starting point should we decide we want to include data URI functionality.