Tags helper isn't available

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?

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

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

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.