Search code examples
node.jsexpressdust.jskraken.js

Can we access the kraken config object in dust template?


My Kraken config in config.json

envConfig : {
     prod : {
        host : "....",
        desc : "..."
    },
     qa : {
         host : "....",
        desc : "..."
    },
} 

Can I access this in my dust template as I wanted to dynamically populate my list or would I have to add it again in my context object for the template


Solution

  • I used ContextDump helper to find that the config is not accessible.I think it makes sense too as we should not expose the configuration information to the client side via dust