Skip to content

Commit

Permalink
adds logic to include aus in the enabled analytic state
Browse files Browse the repository at this point in the history
  • Loading branch information
dskamiotis committed Nov 26, 2024
1 parent fd78c55 commit ca07856
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion dotcom-rendering/src/components/Analytics.amp.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@ type Props = {
export const Analytics = ({
analytics: { comscoreID, section = '', neilsenAPIID, ipsosSectionName },
}: Props) => {
console.log(`section: ${section}`);
const scripts: string[] = [
`<amp-analytics config="https://ophan.theguardian.com/amp.json" data-credentials="include">
<script type="application/json">
Expand Down Expand Up @@ -88,7 +89,7 @@ export const Analytics = ({
`<amp-analytics data-block-on-consent="_till_accepted" config="https://uk-script.dotmetrics.net/AmpConfig.json?dom=www.theguardian.com&tag=${ipsosSectionName}">
<script type="application/json">
{
"enabled": "$EQUALS(\${ampGeo(ISOCountry)}, gb)"
"enabled": "$IF($EQUALS(\${ampGeo(ISOCountry)}, gb),'true', '$EQUALS(\${ampGeo(ISOCountry)}, aus)')"
}
</script>
</amp-analytics>`,
Expand Down

0 comments on commit ca07856

Please sign in to comment.