<!DOCTYPE HTML>
<html>
<head>
<meta charset="UTF-8">
<title>helper-test</title>
<script src="../dist/template-debug.js"></script>
</head>

<body>
<div id="content"></div>
<script id="test" type="text/html">
{{c || a || b}} {{c||a||b}}
{{time | dateFormat:'yyyy年 MM月 dd日 hh:mm:ss'}}
</script>

<script>
template.helper('dateFormat', function (date, format) {
    date = new Date(date);

    var map = {
        "M": date.getMonth() + 1, //月份 
        "d": date.getDate(), //日 
        "h": date.getHou