Comments (4)
Hey @filipagh. I'd like to understand a bit more. If you don't want to link example.com
then set tldMatches
to false
(which you have), and if you want to link http://google.com
you set schemeMatches
to true
(which you also have).
However, with schemeMatches: true
, a URL like http://www.google.com
would have linked in v3.16.2 even if wwwMatches
was set to false
. The wwwMatches
option only applied for non-scheme matches.
Are you saying that you have a use case to link www.google.com
but not google.com
(both scheme-less?)
from autolinker.js.
yes we want link url if it has scheme or has www. on start else leave it as it is
so in same text
[scheme://]www.google.com
scheme://google.com
should be linked
and google.com
should not
from autolinker.js.
Ah, and just so I understand fully: why wouldn't you want google.com
linked in this case?
from autolinker.js.
main reason was that we did not want to parse links in form like google.com
, but we reconsider it and we will parse all valid links
second use case is in mail template
and we do not want link text with that format
like tenant can have its domain name in template which can be like example.com
which is link but not mean to be parsed as link
so use case is to switch mail template format from plain text to html and back
and we expect that plain to html to plain will not change original content
so in this case we want to link only schema / www links where we are sure its link
now this is solved by altering custom html to text formater
so no more need for urls.wwwMatches for us
from autolinker.js.
Related Issues (20)
- Request: Add taiwanese style phone number format
- URL with multiple email addresses in query string is not linked correctly
- Autolinker vulnerable to RTLO URL spoofing attacks HOT 26
- Bug: getUrl method not working correctly for links in markdown formats HOT 1
- doc/release v3.16.0 changelog missing HOT 1
- Links with `¬` in query string are broken
- encoded email address is split
- Wrong result when parsing CJK(中文/日文/韩文) char followed by colon HOT 1
- Failed to parse source map HOT 2
- Add support for YouTube hashtags HOT 1
- Add support for YouTube mentions HOT 1
- Url with protocol prefixed with emoji being incorrectly parsed HOT 1
- Help to create Markdown Link Matcher
- Enable `inlineSources`
- URL as value in key-value pair parsed only partially (and incorrectly)
- [Tiktok mentions] - parsing does not match tiktok mention behaviour HOT 2
- Detection If a Persian word is attached before the link
- Help fix
- إحذر من هذا المتطفل! HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from autolinker.js.