From EJS to Jade
This commit is contained in:
@@ -1,8 +1,5 @@
|
||||
var pejs = require('pejs');
|
||||
var tools = require('../../my_modules/filterInt')
|
||||
|
||||
views = pejs();
|
||||
|
||||
module.exports.index = function(req, res, next) {
|
||||
|
||||
// Parse get argument res
|
||||
@@ -22,7 +19,8 @@ module.exports.index = function(req, res, next) {
|
||||
}
|
||||
|
||||
res.setHeader('Content-Type', 'text/html');
|
||||
views.render('stream/index.html', res.locals, function(err, result) {
|
||||
res.render('index.jade', res.locals, function(err, result) {
|
||||
console.log(err);
|
||||
res.send(result);
|
||||
});
|
||||
}
|
||||
|
||||
18
controllers/stream/views/index.jade
Normal file
18
controllers/stream/views/index.jade
Normal file
@@ -0,0 +1,18 @@
|
||||
extends ../../../views/withjs
|
||||
|
||||
block title
|
||||
title #{title} - Streaming simulator
|
||||
|
||||
block extrajs
|
||||
script params = {}; params.get= {}; params.get.res = #{resolution}
|
||||
script(src="/static/js/stream/main.js")
|
||||
|
||||
block content
|
||||
h2 Streaming simulator
|
||||
|
||||
p.
|
||||
In fact, it's not really streaming. The sphere is fully preloaded and then,
|
||||
a mesh is created and vertices and faces are dynamically added to this mesh
|
||||
as time goes by.
|
||||
|
||||
#container
|
||||
Reference in New Issue
Block a user