szurubooru/client/js/views/home_view.js
rr- 69fe8ec31a client/general: refactor all the things
- Move controls to the "controls/" directory
- Make controls interface look similar to each other
- Prefix "private" methods and attributes with underscore
2016-05-21 00:08:43 +02:00

24 lines
567 B
JavaScript

'use strict';
const config = require('../config.js');
const views = require('../util/views.js');
class HomeView {
constructor() {
this._template = views.getTemplate('home');
}
render(ctx) {
const target = document.getElementById('content-holder');
const source = this._template({
name: config.name,
version: config.meta.version,
buildDate: config.meta.buildDate,
});
views.listenToMessages(source);
views.showView(target, source);
}
}
module.exports = HomeView;