Skip to content
  • 0 Votes
    10 Posts

    @psychobunny the thing is that a lot of controllers (e.g. users: don't have hooks.

    Since it's Express's default behaviour to merge res.locals I wouldn't know why you shouldn't apart from that with NodeBB this will end up on the client side as well if the template will be rendered there. So yes, then maybe res.globals would make sense to allow a plugin to set global variables for all templates to receive. But then.. that wouldn't allow you to do so only for specific templates. Which again means overhead.