{{ $currentPage := .currentPage }} {{ $menuName := .menuName }} {{ $class := slice }} {{ with .context.Page }} {{ if ne .RelPermalink "/" }} {{ $class = $class | append (path.Base .RelPermalink) }} {{ end }} {{ end }} {{ if $currentPage.IsMenuCurrent $menuName .context }} {{ $class = $class | append "active" }} {{ end }}
  • {{ .context.Pre }} {{ $name := .context.Name }} {{ with .context.Page }} {{ with .Params.icon }} {{ $icon := resources.Get . }} {{ $name }} {{ end }} {{ end }} {{ .context.Name }} {{ .context.Post }}