# Loop the repeater in wix website editor

**URL:** <https://forum.wixstudio.com/t/loop-the-repeater-in-wix-website-editor/63414>\
**Category:** Ask the community\
**Tags:** code, question\
**Created:** [October 9, 2024, 11:44pm UTC](https://forum.wixstudio.com/t/loop-the-repeater-in-wix-website-editor/63414 "2024-10-09T23:44:18Z")\
**Posts on this page:** 6\
**Page:** 1

<div class="post-metadata">

**Author:** ![NC\_Robo](https://sea1.discourse-cdn.com/wix/user_avatar/forum.wixstudio.com/nc_robo/32/97976_2.png) [@NC\_Robo](https://forum.wixstudio.com/u/NC_Robo)\
**Post date:** [October 9, 2024, 11:44pm UTC](https://forum.wixstudio.com/t/loop-the-repeater-in-wix-website-editor/63414/1 "2024-10-09T23:44:18Z")

</div>

Hi everyone, How to put loop function to the repeater (connected to dataset). and also to put thumb scroll and put buttons on the side for next and previous items.

---

<div class="post-metadata">

**Author:** ![Dan\_Suhr](https://sea1.discourse-cdn.com/wix/user_avatar/forum.wixstudio.com/dan_suhr/32/94074_2.png) [@Dan\_Suhr](https://forum.wixstudio.com/u/Dan_Suhr)\
**Post date:** [October 10, 2024, 1:21am UTC](https://forum.wixstudio.com/t/loop-the-repeater-in-wix-website-editor/63414/2 "2024-10-10T01:21:05Z")

</div>

add a button and connect it to the dataset. you can then set the action for that button.

adding a loop would require code, maybe something like this

```javascript
function nextItem(dataset) {
        if (dataset.hasNext()) {
            dataset.next();
        } else {
            dataset.setCurrentItemIndex(0); 
        }
    }

```

---

<div class="post-metadata">

**Author:** ![NC\_Robo](https://sea1.discourse-cdn.com/wix/user_avatar/forum.wixstudio.com/nc_robo/32/97976_2.png) [@NC\_Robo](https://forum.wixstudio.com/u/NC_Robo)\
**Post date:** [October 10, 2024, 1:29am UTC](https://forum.wixstudio.com/t/loop-the-repeater-in-wix-website-editor/63414/3 "2024-10-10T01:29:22Z")

</div>

![image](https://us1.discourse-cdn.com/wix/original/3X/a/c/acfdb300f534314f5ff4c57d21ebc897a8977c19.png)

It doesn’t work. It has 9 items in my dataset but I change it to show only 3 so it will look like a slider and put loop.

---

<div class="post-metadata">

**Author:** ![Dan\_Suhr](https://sea1.discourse-cdn.com/wix/user_avatar/forum.wixstudio.com/dan_suhr/32/94074_2.png) [@Dan\_Suhr](https://forum.wixstudio.com/u/Dan_Suhr)\
**Post date:** [October 10, 2024, 3:46am UTC](https://forum.wixstudio.com/t/loop-the-repeater-in-wix-website-editor/63414/4 "2024-10-10T03:46:48Z")

</div>

ahhhhh…old editor. let me see what is the best option

---

<div class="post-metadata">

**Author:** ![Dan\_Suhr](https://sea1.discourse-cdn.com/wix/user_avatar/forum.wixstudio.com/dan_suhr/32/94074_2.png) [@Dan\_Suhr](https://forum.wixstudio.com/u/Dan_Suhr)\
**Post date:** [October 10, 2024, 4:12am UTC](https://forum.wixstudio.com/t/loop-the-repeater-in-wix-website-editor/63414/5 "2024-10-10T04:12:12Z")

</div>

looks like its not possible with the wix editor

> **[Wix Editor Request: Horizontal Scrolling on Repeaters | Help Center | Wix.com](https://support.wix.com/en/article/wix-editor-request-horizontal-scrolling-on-repeaters)**
>
> Currently, it is not possible for your site visitors to scroll through repeaters horizontally. Once the limit of items in the repeater has been reached on one l

---

<div class="post-metadata">

**Author:** ![Dan\_Suhr](https://sea1.discourse-cdn.com/wix/user_avatar/forum.wixstudio.com/dan_suhr/32/94074_2.png) [@Dan\_Suhr](https://forum.wixstudio.com/u/Dan_Suhr)\
**Post date:** [October 10, 2024, 4:15am UTC](https://forum.wixstudio.com/t/loop-the-repeater-in-wix-website-editor/63414/6 "2024-10-10T04:15:30Z")

</div>

maybe this may help sort of get what you need

[![](https://us1.discourse-cdn.com/wix/original/3X/6/7/67373503a393c943e7321288a309e59919aa1541.jpeg "How to Create a Scrollable/Slidable Repeaters in your Wix Website | Lytude help") ](https://www.youtube.com/watch?v=P35iKHlD2vI)
