Motivation
To provide Staticman support for the theme Huginn. You may refer to my recent blog post Huginn theme with Staticman for details.
Demo Frama Pages: https://staticman-gitlab-pages.frama.io/huginn (Source)
Problem
I would like to have a fallback URL (for Staticman API endpoint).
In the Jekyll theme Beautiful Jekyll, it’s done like
<form ...
action="{{ site.staticman.endpoint | default: 'https://staticman-frama.herokuapp.com/v3/entry/github/' }}{{ site.staticman.repository }}/{{ site.staticman.branch }}/comments">
I tried translating this to Hugo, and wrote
<form ...
action="{{ .Site.Params.staticman.endpoint | default 'https://staticman-frama.herokuapp.com/v3/entry/github/' }}...">
and I got
Error: "/home/vin100/huginn/layouts/partials/staticman-comments.html:59:1": parse failed: template: partials/staticman-comments.html:59: malformed character constant: 'https://staticman-frama.herokuapp.com'
How can a URL be supplied as the default value?