Reply view options
Hi,
So I am trying to override or add the partialsPath from the reply.view() :
reply.view('./basket/views/index', {
basket: data
}, {
partialsPath: './client/src/basket/views/'
});
But I get a handlebars error.
My config looks like this
views: {
engines: {
hbs: require('handlebars')
},
path: './client/src/',
layoutPath: './client/src/common/',
layout: true
}
if i add partialsPath: './client/src/basket/views/' to the above views object it works
but I thought I could do it through the reply.view method
Any help is greatly appreciated
-David
You cannot specify additional helpers or partials per view. Only when setting up the views manager.
@hueniverse Is there a way I can point to different partialsPaths? since my partials live in a views directory which live in their own module something like this
basket
└── views
├── index.hbs
├── index.js
└── partial.hbs
and the shipping module has a similar structure.
thanks
nevermind i got it :+1: thanks again
Hi @davidchase , I'm also trying to do this. Can you post your solution?