title: How to add context helper to Dust.js base on server and client
body: <p>I'm working with Dust.js and Node/Express. Dust.js documents the context helpers functions, where the helper is embedded in the model data as a function. I am adding such a function in my JSON data model at the server, but the JSON response to the browser doesn't have the function property (i.e. from the below model, prop1 and prop2 are returned but the helper property is not.</p>
  
  <pre><code>/* JSON data */
  model: {
      prop1: "somestring",
      prop2: "someotherstring",
      helper: function (chunk, context, bodies) {
          /* I help, then return a chunk */
      }
  /* more JSON data */
  </code></pre>
  
  <p>I see that JSON.stringify (called from response.json()) is removing the function property. Not sure I can avoid using JSON.stringify so will need an alternative method of sharing this helper function between server/client. There probably is a way to add the helper functions to the dust base on both server and client. That's what I'm looking for. Since the Dust docs are sparse, this is not documented. Also, I can't find any code snippets that demonstrate this.</p>
  
  <p>Thanks for any help.</p>