If you wanna include }} inside your comment, you can use extended comment: {{!-- comments allow }} inside it --}}
This is a handlebars.js extension, mustache do not support this.
}} can not be placed inside a comment.NULLComment: is not ok }}Comment: is not ok }}require('./vendor/autoload.php');
use LightnCandy\LightnCandy;
$template = "Comment: {{! comment with }} is not ok }}";
$php = LightnCandy::compile($template);
$render = LightnCandy::prepare($php);
$data = NULL;
echo $render($data);
Comment: is not ok }}Comment: is not ok }}var Handlebars = require('handlebars');
var template = 'Comment: {{! comment with }} is not ok }}';
var render = Handlebars.compile(template);
var data = undefined;
console.log(render(data));
}} can be placed inside an extended comment.NULLComment: is ok --}}Comment: require('./vendor/autoload.php');
use LightnCandy\LightnCandy;
$template = "Comment: {{!-- comment with }} is ok --}}";
$php = LightnCandy::compile($template);
$render = LightnCandy::prepare($php);
$data = NULL;
echo $render($data);
Comment: is ok --}}Comment: var Handlebars = require('handlebars');
var template = 'Comment: {{!-- comment with }} is ok --}}';
var render = Handlebars.compile(template);
var data = undefined;
console.log(render(data));