新人求教:使用nunjucks的include功能时,总是提示路径不对
.use(views(__dirname + '/views', {
map: {
html: 'nunjucks'
}
}))
asd.html 和 test.html 同在views文件夹下, test.html代码 {% include “asd.html” %}
错位提示: Template render error: (unknown path) Error: template not found: asd.html
1 回复
前面加上./呢 {% include “./asd.html” %}