From e12408d07bd394f057662fe2670c3157ea78ee75 Mon Sep 17 00:00:00 2001 From: Patrick Marsceill Date: Sat, 2 Feb 2019 12:32:04 -0800 Subject: [PATCH] Add hook for GA tracking --- _config.yml | 4 ++++ _includes/head.html | 15 ++++++++++++++- 2 files changed, 18 insertions(+), 1 deletion(-) diff --git a/_config.yml b/_config.yml index ed1ee2a..5ef47c7 100644 --- a/_config.yml +++ b/_config.yml @@ -31,3 +31,7 @@ aux_links: # Color scheme currently only supports "dark" or nil (default) color_scheme: nil + +# Google Analytics Tracking (optional) +# e.g, UA-1234567-89 +ga_tracking: UA-2709176-10 diff --git a/_includes/head.html b/_includes/head.html index 077564e..ac0fc67 100644 --- a/_includes/head.html +++ b/_includes/head.html @@ -7,8 +7,21 @@ {{ page.title }} - {{ site.title }} + + {% if site.ga_tracking != nil %} + + + + {% endif %} + {% if site.search_enabled != nil %} - + {% endif %}