{{ $class := .Get "class" }} {{ $body := .Get "text" | default .Inner }} <div class="grid{{ with $class }} {{ . }}{{ end }}">{{ $body }}</div>