From 585f71e3a416b23c73da9b31435e0f7469d0a10b Mon Sep 17 00:00:00 2001 From: Alex Le Date: Thu, 28 Feb 2013 14:03:14 -0800 Subject: [PATCH 1/5] Update README.md - update README.md --- README.md | 2 ++ 1 file changed, 2 insertions(+) diff --git a/README.md b/README.md index 0fa61ab..a8464c0 100644 --- a/README.md +++ b/README.md @@ -2,6 +2,8 @@ Express 3.x `layout`, `partial` and `block` template functions for the EJS template engine. +Forked to support contentFor('name') + Previously also offered `include` but you should use EJS 0.8.x's own method for that now. ## Installation From 4f9d2ebcd7d1bc9f0b197349bc45bffd01e152e3 Mon Sep 17 00:00:00 2001 From: Alex Le Date: Thu, 28 Feb 2013 15:49:28 -0800 Subject: [PATCH 2/5] Update README.md - add instruction for contentFor --- README.md | 20 ++++++++++++++++++++ 1 file changed, 20 insertions(+) diff --git a/README.md b/README.md index a8464c0..1c2b49d 100644 --- a/README.md +++ b/README.md @@ -26,6 +26,13 @@ Given a template, `index.ejs`: <% block('header', "

I'm in the header.

") -%> <% block('footer', "

I'm in the footer.

") -%> + <%- contentFor('contentBlock') -%> +

This is the contentBlock

+ + <%- contentFor('contentBlock with space') -%> +

This is the contentBlock with space

+ + And a layout, `boilerplate.ejs`: @@ -41,6 +48,10 @@ And a layout, `boilerplate.ejs`:
<%-body -%> + + <%- contentFor.contentBlock -%> + <%- contentFor["contentBlock with space"] -%> +