Open bazo opened 10 years ago
my file structure is
root - server.js - web/ - templates/ - index.ejs
i configured pejs with
{ basedir: 'web/templates' }
then when i do pejs.render('index') i always get Error: Cannot find module 'index'
i've tried to set the path to
web/templates /web/templates ./web/templates
and also with trailing slash, nothing helps
where's the problem?
Have you tried removing basedir config and using "./web/templates/index" as your path in render? It worked for me on a similar case.
my file structure is
i configured pejs with
then when i do pejs.render('index') i always get Error: Cannot find module 'index'
i've tried to set the path to
and also with trailing slash, nothing helps
where's the problem?