Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
14 changes: 0 additions & 14 deletions index.html
Original file line number Diff line number Diff line change
Expand Up @@ -6,20 +6,6 @@
<title data-askr-head>Askr</title>
<link rel="icon" type="image/png" href="/assets/askr-logo-64.png" />
<link rel="apple-touch-icon" href="/assets/askr-logo-180.png" />
<!-- Google tag (gtag.js) -->
<script
async
src="https://www.googletagmanager.com/gtag/js?id=G-TXZTWQFV59"
></script>
<script>
window.dataLayer = window.dataLayer || [];
function gtag() {
dataLayer.push(arguments);
}
gtag('js', new Date());

gtag('config', 'G-TXZTWQFV59');
</script>
</head>

<body>
Expand Down
8 changes: 8 additions & 0 deletions scripts/verify-static-output.ts
Original file line number Diff line number Diff line change
Expand Up @@ -118,6 +118,14 @@ for (const expectation of expectations) {
!html.includes('/src/'),
`${expectation.route} references source files`
);
assert(
!/<script\b[^>]*\bsrc=["'](?:https?:)?\/\//i.test(html),
`${expectation.route} loads an executable third-party script`
);
Comment thread
smiggleworth marked this conversation as resolved.
assert(
!html.includes('googletagmanager.com') && !html.includes('dataLayer'),
`${expectation.route} contains removed analytics code`
);
assert(
html.includes('/assets/askr-logo-64.avif'),
`${expectation.route} is missing the Askr mark`
Expand Down