javascript - How to access res.locals on client-side -
i'm attempting pass req.user details client-side angular code using res.locals in express route: 'use strict'; var path = require('path'); var player = function(req, res) { res.locals.player = req.player; res.sendfile(path.join(__dirname, '../assets', 'index.html')); }; module.exports = { player: player }; the html renders expected, i'm not sure how access res.locals.player now.