Instructions for Exporting to Word with "live" Zotero Citations

I wrote up a guide for beginners who want to work in Obsidian but then export their document to Word, with Zotero citations seamlessly moving from one app to the other so that they remain editable with the Zotero plugin for Word.

I saw some other guides, but they either had a lot of unnecessary steps, or they skipped stuff that wouldn’t be obvious to beginners.

I welcome any feedback or suggestions!

5 Likes


Hey thanks for the guide!
my H1,H2 and H3 titles have are being added a bracket at he beginning. do you also have this issue?

also I use comments like this one %% comment here %% . is there a way to tell the filter to avois all the content inside those?

Hi @Luhmann,
Thanks for sharing. I could follow your - very clear- tutorial but the export fails. The error message says “Error running filter <My_path_to_lua_filter>: cannot read <My_path_to_lua_filter> is a directory”.
Just to check, does this method still works on your end?

EDIT:
I don’t know whether it is specific to my setup but I solved it by modifying the “extra arguments” command from
--lua-filter=/Users/[name of your user folder]/Documents/obsidian2word
to
--lua-filter=/Users/[name of your user folder]/Documents/obsidian2word/zotero.lua

2 Likes

Thanks for this guide. I have everything set up and it appears to work, but I am running into an issue of certain files not properly converting to live citations. In one document, some citations do convert and some remain in pandoc [@citekey] format. Have you run into this? It’s likely an issue with the .lua but just thought I would ask.

I have the same issue except all my citations are stuck in the pandoc format. When I tried to hit ‘refresh’ in the zotero panel in Word, it said ‘You must insert a citation before performing this action’. Does anyone know where I went wrong? Any help would be appreciated.

Adding /zotero.lua to the extra argument also got me the .docx export, but now I am running into the same issue as folks below. Citations are stuck in pandoc and when I try and refresh, it says (using LibreOffice here): “You must insert a citation before performing this operation.”
Is it still working for you?

Ah! My issue was that I was trying to get it to work with .docx in LibreOffice. I didn’t read the Better BibTeX documentation closely enough. Re-following @Luhmann’s guide, but modifying for export to .odt instead, worked!

Hi Luhmann, Thanks so much for the guide! If I get this to work, it is exactly what I need for my workflow. Unfortunately, when following the steps you lay out in the guide, the export runs into an error and produces nothing. When trying to export a very simple, empty note (with just a title “Untitled” and no content), the console gives this error:

index.html:1 Autofocus processing was blocked because a document already has a focused element.
plugin:obsidian-enhancing-export:28 Uncaught (in promise) TypeError: p is not iterable
at Yn (plugin:obsidian-enhancing-export:28:954)
at HTMLButtonElement .me (plugin:obsidian-enhancing-export:28:9778)
at HTMLDocument.Cc (plugin:obsidian-enhancing-export:4:21366)
Yn @ plugin:obsidian-enhancing-export:28
me @ plugin:obsidian-enhancing-export:28
Cc @ plugin:obsidian-enhancing-export:4

Can you help me out? Thanks in advance!

Kind regards, Laurens