error keeps appearing on line 4
specifically this error:
Liquid syntax error (line 4): Expected close_square but found pipe in "{{settings['carousel_image_' | append: i] }}"
{% for i in (1..100) %}
{% assign image = settings['carousel_image_' | append: i] %}
{% if image != blank %}
{% endif %}
{% endfor %}
{% schema %}
{
"name": "Infinite Carousel",
"settings": [
{% for i in (1..100) %}
{
"type": "image_picker",
"id": "carousel_image_{{ i }}",
"label": "Carousel Image {{ i }}"
}{% if forloop.last == false %},{% endif %}
{% endfor %}
]
}
{% endschema %}
HI @foggystu try this code check if error occurs or not "
{% for i in (1..100) %}
{% assign image_key = 'carousel_image_' | append: i %}
{% assign image = settings[image_key] %}
{% if image != blank %}
{% endif %}
{% endfor %}
.carousel-wrapper {
overflow: hidden;
width: 100%;
position: relative;
}
.carousel {
display: flex;
animation: scroll 10s linear infinite;
}
.carousel-item {
flex: 0 0 auto;
margin-right: 10px;
}
.carousel img {
width: 50px;
height: 50px;
object-fit: cover;
}
@keyframes scroll {
0% { transform: translateX(0); }
100% { transform: translateX(-100%); }
}
{% schema %}
{
“name”: “Infinite Carousel”,
“settings”: [
{% for i in (1..100) %}
{
“type”: “image_picker”,
“id”: “carousel_image_{{ i }}”,
“label”: “Carousel Image {{ i }}”
}{% if forloop.last == false %},{% endif %}
{% endfor %}
]
}
{% endschema %}"