Hi,
I have the rendering block below, but sometimes I need only the author or only the cite attribute, but currently the whole element is dependent on “author”. I would like the presence of a tag to dependent on either author or cite to be set… or be non-empty, as I don’t really know the difference.
Isset seems to do what I want, the problem is I don’t know how to tell “isset this (inclusive) OR that” and no combination has worked so far. “Isset this that” does work but it’s a AND function.
{{ $author := .Attributes.author }}
{{ $cite := .Attributes.cite }}
<figure>
<blockquote {{ with $cite }} cite="{{.| safeHTML }}" {{end}}>
{{ .Inner | markdownify }}
{{ with $author}}<figcaption><cite><strong>
{{.| markdownify }}
</strong>{{with $cite }} in {{$cite|markdownify}}{{end}}</cite>
</figcaption>{{ end }}</blockquote>
</figure>
Thanks