@register.tag
def announcements(parser, token):
 return AnnouncementsNode.handle_token(parser, token)

@ register . tag def announcements ( parser , token ) : return AnnouncementsNode . handle_token ( parser , token )
usage:: {% announcements as var %} returns a list of announcements .