You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The text was updated successfully, but these errors were encountered:
ara4n
changed the title
Links with trailing brackets don't get linkified correctly https://vector.im/develop/#/room/#vector:matrix.org/$1463155004372161mlQnU:matrix.org
Links with trailing brackets don't get linkified correctly
May 24, 2016
Annoyingly, the linkifier we use handles these perfectly (or at least it does in the latest version). The links are mangled when sending by our markdown library which is detecting bare links (part of the it's 'gfm' behaviour).
Options for fixing this are:
Prevent the markdown library from linkifying bare links. Safest, will require setting a rule on the lexer and invoking the marked lexer and parser separately, as they don't expose this as an option. Markdown style urls ending in brackets will still be broken. We'd only have one thing in vector doing linkifying though.
Cease supporting links in markdown at all and strip markdown style links to just the URL (ie. Google would just be turned into 'http://google.com'. This is actually easiest as marked exposes api for it (override the link function).
Try & find a different markdown library that gets link parsing right and hope it doesn't break whatever umpteen other things it turns out we've been relying on. Still have two things in the codebase that do linkification.
Created by @ matthew:matrix.org.
The text was updated successfully, but these errors were encountered: