Use of swig plus express

  node.js, question

After swig is set as express’s default engine, each res.render (‘index’,’ title:’ title’}}); Can be called in the template, there are some user information after login, for example, how can I call it?

Some basic information should be put in the session, such as req.session.uname, render to the template

Swing seems to be able to introduce other templates, so it is necessary to separate the common parts into separate templates.

Other information may have to be dynamically brushed into the page through ajax calls.