Closed littlebenlittle closed 2 years ago
The relevant code for include
resolution is here: https://github.com/mde/ejs/blob/main/lib/ejs.js#L156
But I think the root
and views
options documented in the README and on the Web site will give you what you need.
I cannot get include to work in EJS templates using this script:
build.js
Directory structure
index.ejs
Running this with
node build.sh
results inCould not find the include file "src/partials/intro.ejs"
. I have tried using "./partials/intro.ejs" too.It would be very helpful to understand how EJS is trying to resolve paths.