acrylamid icon indicating copy to clipboard operation
acrylamid copied to clipboard

Proposal: add an entry.description boolean argument

Open andreamoro opened this issue 10 years ago • 3 comments

Playing around with Acrylamid I felt very uncomfortable having entry.description returning a trimmed version of entry.content.

As I appreciate many users could have been using this as a feature, I'd like to propose the inclusion of a boolean parameter in the call to allow new sites being developed not including the description if the argument is set to false.

There is an SEO reason behind, and being able to control whether the description is empty or not could offer other choices other than arbitrarily accepting the value currently returned.

andreamoro avatar Dec 07 '14 05:12 andreamoro

You can include a description in the YAML front matter of each entry.

In addition, I have also added an content.sdescription which you can use in the template body for your SEO needs (see #212).

geekman avatar Dec 07 '14 05:12 geekman

I know that I can add a new field, in fact I have temporarily added a field called description to override the problem. But if I forget to add the entry, or even if you don't define the sdefinition the problem is still there hence the proposal.

andreamoro avatar Dec 07 '14 05:12 andreamoro

You can also disable the inclusion of entry.description by removing the relevant parts from the template (and replace it with a custom version, either generated or manually written). It is just a convenience attribute.

posativ avatar Dec 07 '14 22:12 posativ