29 lines
1.4 KiB
HTML
29 lines
1.4 KiB
HTML
{%- if not config.extra.disable_javascript %}
|
|
{%- if page.extra.mermaid | default(value=(section.extra.mermaid | default(value=config.extra.mermaid))) %}
|
|
{% include "partials/mermaid.html" %}
|
|
{%- endif %}
|
|
{%- if config.extra.goatcounter.endpoint %}
|
|
{%- if config.extra.goatcounter.src %}
|
|
{%- set goatcounter_src = config.extra.goatcounter.src %}
|
|
{%- elif config.extra.use_cdn %}
|
|
{%- set goatcounter_src = "//gc.zgo.at/count.js" %}
|
|
{%- else %}
|
|
{%- set goatcounter_src = m_url::rel(there=get_url(path=`js/gc.min.js`, cachebust=true), here=g_here, base=g_base) %}
|
|
{%- endif %}
|
|
<!-- GoatCounter -->
|
|
<script>window.linkita.initGoatCounterAnalytics({
|
|
src: "{{ goatcounter_src | escape_xml | safe }}",
|
|
endpoint: "{{ config.extra.goatcounter.endpoint | escape_xml | safe }}"
|
|
});</script>
|
|
{%- if config.extra.goatcounter.noscript_prefix is defined and current_path is defined %}
|
|
<noscript><img src="{{ config.extra.goatcounter.endpoint | escape_xml | safe }}?p={{
|
|
config.extra.goatcounter.noscript_prefix ~ current_path | urlencode | safe }}" alt=""></noscript>
|
|
{%- endif %}
|
|
{%- endif %}
|
|
{%- if config.extra.vercel_analytics.src %}
|
|
<!-- Vercel Web Analytics -->
|
|
<script>window.linkita.initVercelAnalytics({
|
|
src: "{{ config.extra.vercel_analytics.src | escape_xml | safe }}"
|
|
});</script>
|
|
{%- endif %}
|
|
{%- endif %}
|