wagtailnews icon indicating copy to clipboard operation
wagtailnews copied to clipboard

Template usage is undocumented

Open JOJ0 opened this issue 4 years ago • 1 comments

Hi, I had a hard time trying to figure out how to use wagtailnews in templates. I had to use template debugging tools to finally find out that these variables are mainly to be used:

newsitem_list
newsitem_page
newsitem_view

newsitem_list can be iterated through to receive a list of news pages / blog posts. That was the most important thing for me to find out by experimenting.

I am a wagtail beginner more or less, so please point me in the right direction if this would have been found somewhere in the docs or could be otherwise retrieved by reading code - In any case, mentioning it at least in you README.md is essential, at least to my understanding.

Thanks a lot for wagtailnews! :-) and all the best, Jojo

JOJ0 avatar Dec 28 '20 12:12 JOJ0

Fair call, some extra documentation would help peolpe find that info, at the moment you could only find that out by looking at the source.

I think the best place would be under 'Usage' in the docs with a bit of info about how to setup your templates for use with wagtailnews. Thanks for pointing this out :+1:

seb-b avatar Jan 04 '21 03:01 seb-b