1

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 Answers1

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 ()
  (save-excursion
    (forward-word -1)
    (not (looking-back "@"))))

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

scaramouche
  • 1,772
  • 10
  • 24