robinst / autolink-java

Java library to extract links (URLs, email addresses) from plain text; fast, small and smart
MIT License
207 stars 40 forks source link

Linkify domain-only links (without scheme or www) #30

Open theyuv opened 5 years ago

theyuv commented 5 years ago

Thanks for your library.

Would you consider adding a LinkType for just domains (eg: example.com)?

There are some cases where this is considered a link and needs to be detected/extracted (eg: Gmail and Twitter detect domains like these as links and turn them into an anchor tag).

Thanks again.

robinst commented 5 years ago

Hey! Yeah, extraction of plain domains would be handy. I think we'd need to be able to specify an "include list" of domains that should be detected, otherwise it tends to detect a lot of false positives. Or we'd ask the caller to do that themselves.

Anyway, I added a "help wanted" label and welcome pull requests for this.