Closed maelle closed 3 years ago
Thank you! I'll look into that. I did the GA tag following tidytemplate, not sure how that differs from injecting the GA tag into the yaml? https://github.com/tidyverse/tidytemplate/blob/b819e3028b4b9342aeac238de147821bbb4c517c/inst/pkgdown/templates/head.html#L79-L87
https://pkgdown.r-lib.org/reference/build_site.html#yaml-config-template
I think the problem with GA in YAML is that there is no good way yet to share the ID without asking all users of the template package to put the YAML field in their pkgdown config file. Related to https://github.com/r-lib/pkgdown/issues/1499
Since you are using dev pkgdown anyway, do you think that instead of using a template for head.html you could put all your overrides in in-header.html? See https://pkgdown.r-lib.org/dev/news/index.html#pkgdown-development-version-unreleased
I had a look at your head.html and I'm not sure you only add things, though. E.g. you directly write the GA tag which you couldn't do via in-header.html.