parse.html 573 B

123456789101112131415161718192021
  1. {{ $return := "" }}
  2. {{ with site.Data.wowchemy_cms_tpl }}
  3. {{ $return = . }}
  4. {{ end }}
  5. {{ $backend_opts := dict "branch" (site.Params.cms.branch | default "main") }}
  6. {{ with site.Params.cms.publish_mode }}
  7. {{ $publish_mode := dict "publish_mode" . }}
  8. {{ $return = merge $return $publish_mode }}
  9. {{ end }}
  10. {{ if site.Params.cms.local_backend }}
  11. {{ $local_backend := dict "local_backend" true }}
  12. {{ $return = merge $return $local_backend }}
  13. {{ end }}
  14. {{ $backend := dict "backend" $backend_opts }}
  15. {{ $return := merge $return $backend }}
  16. {{- return $return -}}