Skip to content

stencil.ReadDir

ReadDir reads the contents of a directory and returns a list of files/directories

go
{{ range $entry := stencil.ReadDir "/tests" }}
  {{ if $entry.IsDir }}
    {{ $entry.Name }}
  {{ end }}
{{ end }}