相关疑难解决方法(0)

在Jekyll中,include_relative对于布局文件如何工作?

我有一个名为default.html我的layouts文件夹中。在中default.html,我想添加一个相include对于的相对对象test.html,它也在我的layouts文件夹中。

{% include_relative test.html }%default.html文件中添加include test.html。但是,当我这样做时,我得到一个错误,指出

"Liquid Exception: Included file './test.html' not found in
projects/[projectnmae]/layouts/default.html"
Run Code Online (Sandbox Code Playgroud)

我的layouts文件夹确实位于配置文件中指定的其他位置。有什么想法include_relative可以以一种我不掌握的特殊方式起作用吗?

relative-path include jekyll

3
推荐指数
2
解决办法
2554
查看次数

标签 统计

include ×1

jekyll ×1

relative-path ×1