Warning: file_get_contents(/data/phpspider/zhask/data//catemap/4/jquery-ui/2.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Liquid 如果代码段位于条件语句中,则不会更新液体模板_Liquid_Locomotivecms - Fatal编程技术网

Liquid 如果代码段位于条件语句中,则不会更新液体模板

Liquid 如果代码段位于条件语句中,则不会更新液体模板,liquid,locomotivecms,Liquid,Locomotivecms,更新页面中包含的代码段后,除非开发人员更新页面,否则页面上的更改(代码段更改)不会发生。因此,在触发代码段更改时,以下是工作流程: => update snippet content => update page (change something, click save) => hard reload the page in the browser to that change 这不是自动更新的,我需要在页面上添加任何字符,保存它,然后删除它,然后再次保存 对于单个页面来说,这很好,但是当有多

更新页面中包含的代码段后,除非开发人员更新页面,否则页面上的更改(代码段更改)不会发生。因此,在触发代码段更改时,以下是工作流程:

=> update snippet content => update page (change something, click save) => hard reload the page in the browser to that change 这不是自动更新的,我需要在页面上添加任何字符,保存它,然后删除它,然后再次保存

对于单个页面来说,这很好,但是当有多个页面需要更新时,问题就会出现

目前的工作流程如上所述

{% if entry.category == 'Recipes' %} {% assign body_class = 'recipes' %} {% else %} {% assign body_class = 'nutrition article' %} {% endif %} {% extends 'index' %} {% block 'halo/breadcrumbs' %} Home> Nutrition> {{ entry.title }} {% endblock %} {% block 'wrapper/main-content' %} {% if entry.category == 'Recipes' %} {% include 'recipes-content' %} {% else %} {% include 'nutrition-content' with entry_slug: entry._slug %} {% endif %} {% endblock %}
{% include 'recipes-content' %}