Skip to content
Snippets Groups Projects
Commit 8e5f1894 authored by Benjamin Bertrand's avatar Benjamin Bertrand
Browse files

Create extension to render JIRA TAG links

See https://github.com/showdownjs/showdown/wiki/Extensions
parent 94fe48e2
No related branches found
No related tags found
No related merge requests found
......@@ -6,7 +6,17 @@ $(document).ready(function() {
scrollBy(0, -100);
}
// Showdown extension to render links to JIRA TAG project
var jira_tag = {
type: 'lang',
regex: /(TAG-\d+)/g,
replace: '[$1](https://jira.esss.lu.se/browse/$1)'
};
// Register the extension
showdown.extension('jira_tag', jira_tag);
var converter = new showdown.Converter({
extensions: ['jira_tag'],
simplifiedAutoLink: true
});
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment