{{ $targetPath := "js/main.js" }}
{{ $main := resources.Get $targetPath }}
{{ with $main }}
{{ $js := . | resources.Minify }}
<script type="text/javascript" src="{{ $js.Permalink }}"></script>
{{ end }}
{{ if or (eq hugo.Environment "production") (eq hugo.Environment "staging") }}
<script defer data-domain="{{if eq hugo.Environment "staging" }}staging.{{ end }}lestoitsduval.fr" src="https://analytiques.resilien.cloud/js/plausible.js"></script>
<script>window.plausible = window.plausible || function() { (window.plausible.q = window.plausible.q || []).push(arguments) }</script>
{{ end }}
