Closed ghost closed 9 years ago
Guessing you are running dust on the server rather than in the client?
Yes, only using server side templates.
I am guessing, because I can't test this right now, that the problem is that you are requiring in the helpers before anything requires in dust. If you try this...
require('dustjs-linkedin');
require('dustjs-helpers');
...does that work?
Keep in mind that Mimosa is primarily a browser development tool. I've made it so that mimosa new
delivers to you a basic server for Express, but all Mimosa does is call startServer
and allow for some basic configuration to help get things started a bit faster. Once you start diverging from that basic setup, you sort of stop being really all that involved with Mimosa and really start taking ownership of the server code... which is a good thing!
Thanks for the reply! I just had to npm install dustjs-helpers. Using the "require" lines actually stops the helpers for loading for some reason.
All set then? This closeable?
Yes, thank you David.
Hi,
Where would I put a custom dust-js helper, such as:
I also tried adding a
require('dustjs-helpers')
to my express server.coffee but that didn't seem to have any effect.