photosite/test/templates.js

14 lines
326 B
JavaScript
Raw Normal View History

2024-01-06 05:25:07 +00:00
const { createLog } = require('../dist/log');
const { Templates } = require('../dist/templates');
const log = createLog('tmpl-test');
(async function main () {
const tmpl = new Templates('./views');
try {
await tmpl.build();
} catch (err) {
log.error(err);
}
log.info(tmpl.render('index', { body : 'test' }));
})()