Smart Links
approvedby David Lynch
Automatically detect strings using regular expressions and turn them into links in reading view. Useful for stock symbols, issue tracking, etc.
Obsidian Smart Links
This is a plugin for Obsidian that lets you define custom "smart" links which will be auto-linked when reading documents.
If you're used to writing in an environment that auto-links certain strings and don't want to build new habits, this will help with that. E.g. T12345 in phabricator, or #4324 in github.
It'll turn this...

Into this...


You can add your own replacement patterns in Obsidian's settings:

Usage
Install and enable the plugin. Once you do, you'll find there's a new section in your settings called "Smart Links". In it you can add/remove replacement rules. You'll need to write a regular expression and a replacement string for it. This can range from very simple to very complicated.
| Regular expression | Replacement |
|---|---|
T\d+ | https://phabricator.wikimedia.org/$& |
\$([A-Z]+) | https://finance.yahoo.com/quote/$1 |
go\/[_\d\w-/]+ | http://$& |
The replacements work using normal Javascript regular expression replacement syntax. I'm so very sorry. Remember that you'll need to escape characters with special meaning in regular expressions. Matches are restricted so they'll only occur immediately after either the start of a line or some whitespace.
Credits
The reading-mode code was heavily influenced by Obsidian GoLinks -- this plugin is (arguably) a customizable superset of that one's functionality.
For plugin developers
Search results and similarity scores are powered by semantic analysis of your plugin's README. If your plugin isn't appearing for searches you'd expect, try updating your README to clearly describe your plugin's purpose, features, and use cases.