Automated conversion of Zotero tags to clickable links in obsidian using code in literature notes template?

What I’m trying to do

Hi, I am fairly new to Obsidian but know the basics, maybe someone can help.

Overview: I have linked my Obsidian Vault to Zotero and use the following plugins: Zotero Integration, Better BibTex, ZotFile, Dataview, Templater.
Using my template for literature notes works fine. It shows all the tags that were created in Zotero.

My question: to optimize my workflow, I would like to have the tags displayed as links instead of hashtags. Is this possible? How?

Things I have tried

Actually, I’m pretty sure I picked up this exact information or the necessary code somewhere, but I just can’t find the source anymore.

Right now I´m using the code “{% if hashTags %}Tags: {{hashTags}}{% endif %}” and it works fine but doesn´t satisfy my needs.

I know I could add them manually, but maybe someone has a better solution.

Thank you in advance!

lynade

How about going back to the horse’s mouth and modfying whatever template you are using?
No need to do search and replace then.

Hello gino_m,

I am unsure if we mean the same thing. Actually, that’s what I want…to change the code in my template, but only the code that converts tags to links when I read in literature data via the Zotero Integration Plugin. Unfortunately, I have no experience in programming, so I don’t know how to change the code at all.

If it is internal links you’re after, you put in double square brackets, [[iwasatagbefore]].

so do you mean I should rewrite “{% if hashTags %}Tags: {{hashTags}}{% endif %}” as a link, like this: “[{% if hashTags %}Tags: {{hashTags}}{% endif %}]”? If I do that, it’s still just tags and not links that create a new note. I´m sorry if I misunderstand you.

Are your tags tied to individual highlights? I thought they were in the frontmatter. I don’t know the proper syntax, so I guess you need to play around. Wasn’t paying attention, sorry.

I had a typo, I meant double [[…]], “[[{% if hashTags %}Tags: {{hashTags}}{% endif %}]]”. Unfortunately that also doesn´t work.

oh, sorry for the misunderstanding, it’s not about the frontmatter.

thank you for taking the time to help me solve this problem, perhaps I will do without. I already tried changing the code and looking for answers, but could not find a solution yet.

I was thinking more along the lines of {% if hashTags %}Tags: [[{{hashTags}}]]{% endif %} or something. Play around with it.

Ok, thank you. I tried different modifications today, but still don´t have a solution. Thanks for your effort. I will write it here, if I find a solution.

Have you tried {% if hashTags %}Tags: [[{{hashTags}}]]{% endif %}?

yes, thank you, that doesn´t work either.

Then you must have by now tried:

{% if hashTags %}Tags: {{[[hashTags]]}}{% endif %}

Hi! Did you ever solve this? I would like the exact same thing. It make sense from a Academic-Obsidian-Zotero workflow if one wants to focus on Links.