Hi,
I’ve noticed that when creating a static page and routing to it using the yaml config file the {{tags}} helper isn’t available.
routes:
/: home
/develop/staticpage/:
data:
post: page.staticpage
template: staticpage
Has anybody else come across this?
Hannah
March 13, 2019, 10:53pm
2
Which version of Ghost are you on please?
1 Like
Hi Hannah,
Ghost-CLI version: 1.9.9
Ghost version: 2.17.2
If it helps here’s a test template file that I created when looking into the issue. On further investigation it looks like that author isn’t being pulled through too.
{{!< default}}
{{> "header"}}
{{#post}}
<p>author = {{authors}}</p>
<p>tags = {{tags}}</p>
{{/post}}
Thanks
James
Kate
March 14, 2019, 12:48pm
5
I assume you are running into this issue .
Dynamic routing is in still in beta and we already have received some bug reports for static pages using the data key.
Possible workarounds:
use post instead of page for now?
fetch the target page with tags/authors using the {{#get …}} helper
Thanks the {{#get …}} helper seems to be a good workaround for what I require
system
Closed
March 28, 2019, 1:13pm
7
This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.