Skip to content

Add Support for Lambda sections#25

Open
drbawb wants to merge 6 commits into
hoisie:masterfrom
drbawb:master
Open

Add Support for Lambda sections#25
drbawb wants to merge 6 commits into
hoisie:masterfrom
drbawb:master

Conversation

@drbawb
Copy link
Copy Markdown

@drbawb drbawb commented Sep 9, 2012

I've added lambda support and three supporting test cases.

The first case shows that "sections" inside "lambdas" are passed unexpanded. (As per my interpretation of the mustache spec.)
You'd need to call render inside the lambda to expand those sections.

The second and third cases show that lambdas nested in sections now works properly.

Robert Straw added 3 commits September 9, 2012 11:21
when [boolean] section is false, lambda should not be shown
@chrneumann
Copy link
Copy Markdown

Works for me, thanks!

The text of a lambda tag is passed to the function as an
[]string of arguments now.

The text is split by (' ').split by (' ').

This change is untested, it is under development for the project
`babou` -- which is available at `github.com/drbawb/babou`.
Conflicts:
	mustache.go
	mustache_test.go
(Apparently go-fmt didn't like something.)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants