Flyspell regularly shows pandoc citations as a spelling error in markdown documents. For example @chu2017 will come up as a spelling error for 'chu'.

How can I get Flyspell ignore the citations and only check other words in the document?

1 Answer 1


Try adding the following to your init.el:

(add-hook 'markdown-mode-hook
          '(lambda ()
             (setq flyspell-generic-check-word-predicate 'my-pandoc-flyspell-verify)))

(defun my-pandoc-flyspell-verify ()
    (forward-word -1)
    (not (looking-back "@"))))

Essentially, it is telling flyspell not to check words that start with "@".

  • Awesome, thanks @scaramouche, that does the trick! Feb 12, 2020 at 10:28

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.