2 var f = $(this), app = $$(this).app;
3 var Mustache = app.require("lib/mustache");
4 var markdown = app.require("vendor/couchapp/lib/markdown");
7 name : $$("#profile").profile.nickname,
8 url : $$("#profile").profile.url,
9 avatar : $$("#profile").profile.gravatar_url,
10 html : markdown.encode(Mustache.escape($("[name=comment]", f).val())),
11 created_at : JSON.parse(JSON.stringify(new Date()))
14 $("#comment-preview").html(Mustache.to_html(app.ddoc.templates.partials.comment, c));