Is it possible to assign a block to a variable, to then manipulate in the base before outputting?
For example, could I change:
<!DOCTYPE html>
<html>
<body>
<main >
{{- block "main" . }}{{- end }}
</main>
</body>
</html>
to something along the lines of:
{{$mainBlock := block "main" . }}
<!DOCTYPE html>
<html>
<body>
<main >
{{ $mainBlock }}
</main>
</body>
</html>
The main reason is that I’d like to use findRegex on the $mainBlock
content and manipulate the head based on that.