Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

POD documentation shows escaped way to enclose content instead of unescaped content in layout. #1

Closed
VinceW opened this issue Sep 11, 2014 · 1 comment

Comments

@VinceW
Copy link

VinceW commented Sep 11, 2014

When playing around with dancer to give mustache a quick look, I noticed a (small) error in the POD documentation. Line 98-100 in Mustache.pm says:

<body>
{{ content }}
</body>

When providing an index.mustache to the {{content}} (usual dancer way), this gets all escaped.

The mustache documentation (http://mustache.github.io/mustache.5.html) says:
All variables are HTML escaped by default. If you want to return unescaped HTML, use the triple
mustache: {{{name}}}.

I tried this in my layout file and the content (index.mustache) got properly displayed.

<body>
{{{ content }}}
</body>

a) is this intentional behaviour?
b) If, not ... is the proposed solution correct?
c) if so, do you want me to file a pull request for this?

Best,
VinceW

BTW: tnx 4 all ur efforts on Dancer.

@yanick
Copy link
Owner

yanick commented Sep 13, 2014

I think you are right.

You can submit a PR if you want. Or I can just tweak the code -- it'll be a 2 characters affair.

And thanks for the kind words. It's muchly appreciated. ^.^

@yanick yanick closed this as completed Sep 14, 2014
yanick pushed a commit that referenced this issue Sep 15, 2014
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

No branches or pull requests

2 participants