⚡ Improve page scripts configuration files.
This commit is contained in:
10
layouts/partials/_thirdparty/analytics/51la.html
vendored
10
layouts/partials/_thirdparty/analytics/51la.html
vendored
@@ -4,12 +4,14 @@
|
||||
|
||||
script.charset = "UTF-8";
|
||||
script.id = "LA_COLLECT";
|
||||
script.src = "{{ .ctx.Site.Data.resources.analytics.la }}";
|
||||
script.src = "{{ .Site.Data.resources.analytics.la }}";
|
||||
script.async = "true"
|
||||
script.onload = function() {
|
||||
LA.init({ id: "{{ .id }}",ck: "{{ .id }}", autoTrack:true });
|
||||
{{ with .Site.Params.analytics.laId }}
|
||||
LA.init({ id: "{{ . }}",ck: "{{ . }}", autoTrack:true });
|
||||
{{ end }}
|
||||
}
|
||||
|
||||
document.head.appendChild(script);
|
||||
});
|
||||
document.head.appendChild(script);
|
||||
});
|
||||
</script>
|
||||
|
||||
Reference in New Issue
Block a user