LukeEmmet / duckling-proxy

Duckling proxy 🦆 is a Gemini proxy to access the Small Web
MIT License
34 stars 5 forks source link

Convert simple link in a para or bullet to gemini link #8

Open LukeEmmet opened 3 years ago

LukeEmmet commented 3 years ago

Duckling emits all text, then a list of links as it goes through. This works well for links inside a paragraph, but for simple lines that are just a link, it results in two items, one for the text, then another for the link.

If the scanner detects a paragraph, or list item that is just itself a link, it should perhaps just emit a link, and skip emitting the text as well.

For example, consider this page, which is simple text and links https://drewdevault.com/