We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent b19e9e6 commit d76b438Copy full SHA for d76b438
plugin/markdown_extras.vim
@@ -50,7 +50,12 @@ if use_prettier
50
else
51
augroup MARKDOWN_EXTRAS_PRETTIER_CHECK
52
autocmd!
53
- autocmd BufReadPost *.md,*.markdown,*.mdown,*.mkd ++once
+ # TODO: Changing BufReadPre with FileType markdown won't work because
54
+ # FileType markdown autocmd is executed after ftplugin/markdown.vim is sourced,
55
+ # and therefore ftplugin/markdown.vim would see use_prettier = true all
56
+ # the time. Hence, the hack is to use BufReadPre and to specify all the
57
+ # possible file extensions.
58
+ autocmd BufReadPre *.md,*.markdown,*.mdown,*.mkd ++once
59
\ PrettierInstalledCheck()
60
augroup END
61
endif
0 commit comments