 $showFlexSearch = or (eq (len .Site.Params.options.searchSectionsShow) 0) (in .Site.Params.options.searchSectionsShow .Section) (and .IsHome (in .Site.Params.options.searchSectionsShow "HomePage")) -}}
  {{ end -}}
{{ end -}}

{{ if .Site.Params.options.darkMode -}}
  {{ $darkMode := resources.Get "js/darkmode.js" -}}
  {{ $darkMode := $darkMode | js.Build -}}
  {{ $slice = $slice | append $darkMode -}}
{{ end -}}

{{ if and (.Site.Params.alert) (.Site.Params.alertDismissable) -}}
  {{ $alert := resources.