Skip to content

Commit

Permalink
add docs for plausible
Browse files Browse the repository at this point in the history
  • Loading branch information
maelle committed Sep 20, 2024
1 parent d51a610 commit 80f0454
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 0 deletions.
1 change: 1 addition & 0 deletions R/use-poisson-pkgdown.R
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,7 @@ use_poisson_pkgdown <- function(pkg = getwd()) {
cat(paste(cli::symbol$tick, "Registered poissontemplate in pkgdown config.\n"))
cat(paste(cli::symbol$bullet, "Check that the config edits are all harmless.\n"))
cat(paste(cli::symbol$bullet, "Git commit and push to origin.\n"))
cat(paste(cli::symbol$bullet, "Contact Poisson consulting plausible owner to set up subdomain.\n"))

# TODO: traffic analytics setup?
}
Expand Down
9 changes: 9 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,15 @@ In every package where you need to set up poissontemplate usage, run
poissontemplate::use_poisson_pkgdown()
```

Then contact the owner of Poisson consulting Plausible account to have a domain set up.
Once it is done, amend and add the following lines to the pkgdown configuration file:

```yaml
includes:
in_header: |
<script defer data-domain="{YOUR DOMAIN},poissonconsulting.ca" src="https://plausible.io/js/plausible.js"></script>
```
## Relevant resources
- pkgdown documentation about theming: https://pkgdown.r-lib.org/articles/customise.html#theming
Expand Down

0 comments on commit 80f0454

Please sign in to comment.