This commit is contained in:
Tommy Parnell
2023-12-04 13:35:06 -05:00
parent 7de6259fb2
commit 1c28f44f15
6 changed files with 36 additions and 1 deletions

1
.gitignore vendored
View File

@@ -1,2 +1,3 @@
_site/ _site/
node_modules/ node_modules/
.env

7
_data/process.js Normal file
View File

@@ -0,0 +1,7 @@
require('dotenv').config()
module.exports = function() {
return {
env: process.env
};
};

9
_includes/gtm.njk Normal file
View File

@@ -0,0 +1,9 @@
<!-- Google tag (gtag.js) -->
<script async src="https://www.googletagmanager.com/gtag/js?id=G-0XH9HYVENB"></script>
<script>
window.dataLayer = window.dataLayer || [];
function gtag(){dataLayer.push(arguments);}
gtag('js', new Date());
gtag('config', 'G-0XH9HYVENB');
</script>

View File

@@ -2,6 +2,10 @@
<html lang="en"> <html lang="en">
<head> <head>
<meta charset="utf-8" /> <meta charset="utf-8" />
{% if process.env.DISABLE_GTM and process.env.DISABLE_GTM !== "false" %}
{% else %}
{% include "gtm.njk" %}
{% endif %}
<title>{{ title or metadata.title }}</title> <title>{{ title or metadata.title }}</title>
{% include './meta.njk' %} {% include './meta.njk' %}

13
package-lock.json generated
View File

@@ -15,6 +15,7 @@
"@11ty/eleventy-plugin-bundle": "^1.0.4", "@11ty/eleventy-plugin-bundle": "^1.0.4",
"@11ty/eleventy-plugin-rss": "^1.2.0", "@11ty/eleventy-plugin-rss": "^1.2.0",
"@11ty/eleventy-plugin-syntaxhighlight": "^5.0.0", "@11ty/eleventy-plugin-syntaxhighlight": "^5.0.0",
"dotenv": "^16.3.1",
"html-minifier": "^4.0.0", "html-minifier": "^4.0.0",
"luxon": "^3.3.0", "luxon": "^3.3.0",
"markdown-it-anchor": "^8.6.7" "markdown-it-anchor": "^8.6.7"
@@ -1007,6 +1008,18 @@
"url": "https://github.com/fb55/domutils?sponsor=1" "url": "https://github.com/fb55/domutils?sponsor=1"
} }
}, },
"node_modules/dotenv": {
"version": "16.3.1",
"resolved": "https://registry.npmjs.org/dotenv/-/dotenv-16.3.1.tgz",
"integrity": "sha512-IPzF4w4/Rd94bA9imS68tZBaYyBWSCE47V1RGuMrB94iyTOIEwRmVL2x/4An+6mETpLrKJ5hQkB8W4kFAadeIQ==",
"dev": true,
"engines": {
"node": ">=12"
},
"funding": {
"url": "https://github.com/motdotla/dotenv?sponsor=1"
}
},
"node_modules/duplexer": { "node_modules/duplexer": {
"version": "0.1.1", "version": "0.1.1",
"resolved": "https://registry.npmjs.org/duplexer/-/duplexer-0.1.1.tgz", "resolved": "https://registry.npmjs.org/duplexer/-/duplexer-0.1.1.tgz",

View File

@@ -39,6 +39,7 @@
"@11ty/eleventy-plugin-bundle": "^1.0.4", "@11ty/eleventy-plugin-bundle": "^1.0.4",
"@11ty/eleventy-plugin-rss": "^1.2.0", "@11ty/eleventy-plugin-rss": "^1.2.0",
"@11ty/eleventy-plugin-syntaxhighlight": "^5.0.0", "@11ty/eleventy-plugin-syntaxhighlight": "^5.0.0",
"dotenv": "^16.3.1",
"html-minifier": "^4.0.0", "html-minifier": "^4.0.0",
"luxon": "^3.3.0", "luxon": "^3.3.0",
"markdown-it-anchor": "^8.6.7" "markdown-it-anchor": "^8.6.7"