I find poly-r-rmarkdown-templates-menu takes so long to build them menu items with the dozens of available templates (order 5 seconds, in my hands at least), and apparently has to be repopulated on every menubar selection, thus making all menus unusable.
My workaround is to redefine the menu in my init.el as follows:
(easy-menu-define poly-markdown+R-menu (list ess-mode-map
inferior-ess-mode-map
poly-markdown+r-mode-map)
"Menu for poly-r+markdown-mode"
'("RMarkdown"
("Templates - too slow! Disabled in your init.el!"
;;:active (ess-get-next-available-process "R" t)
:filter ignore)))
Could the results be computed once, asynchronously, and cached (possible for each different installation of R it is used with)?