Skip to content

Commit

Permalink
Add more custom properties to be tracked (#3778)
Browse files Browse the repository at this point in the history
We just released support for multiple custom property filters, but our demo/live setup
does not have many useful custom properties. This PR adds a few more to allow
better slicing-and-dicing.
  • Loading branch information
macobo authored Feb 12, 2024
1 parent 1cb7982 commit 499be9f
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion lib/plausible_web/templates/layout/_tracking.html.heex
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,9 @@
plausible('pageview', {
u: pageUrl,
props: {
logged_in: <%= is_map(@conn.assigns[:current_user]) %>
logged_in: <%= is_map(@conn.assigns[:current_user]) %>,
theme: '<%= if @conn.assigns[:current_user], do: @conn.assigns[:current_user].theme, else: "system" %>',
browser_language: navigator.language || navigator.userLanguage
}
})
</script>
Expand Down

0 comments on commit 499be9f

Please sign in to comment.