nitdoc: short init with content for TplArticle
authorAlexandre Terrasa <alexandre@moz-code.org>
Thu, 19 Jun 2014 19:58:31 +0000 (15:58 -0400)
committerAlexandre Terrasa <alexandre@moz-code.org>
Thu, 26 Jun 2014 18:59:39 +0000 (14:59 -0400)
Signed-off-by: Alexandre Terrasa <alexandre@moz-code.org>

src/doc/doc_templates.nit

index ce4949b..3ead15b 100644 (file)
@@ -455,6 +455,11 @@ class TplArticle
        # Content for this article
        var content: nullable Streamable writable = null
 
+       init with_content(id: String, title: Streamable, content: Streamable) do
+               with_title(id, title)
+               self.content = content
+       end
+
        # CSS classes to apply on the article title heading element
        var title_classes = new Array[String]