Reverse repeat

Thanks!

Update: In fact, the problem I wrote about above is not infinite scrolling. Infinite scrolling, can be recreated in the Wappler very easily, with the help of pagination + a small script.

What I write about in this thread, in principle, is also not difficult to do yourself, just by writing your own repeat function. But perhaps it makes sense for the Wappler to add an additional setting to the repeat component?

This idea arose for three reasons:

  1. With a custom solution, it will be more difficult to work, and therefore less effective.
  2. This setting can be useful for many users. More precisely, anyone who wants to build the functionality of the messenger in their application based on the Wappler.
  3. This setting is implemented very easily in App Connect (at least at first glance).

This is about the dmx.repeatItems function in App Connect. Now it works so that after checking the data type, it proceeds to add elements to the array e using the push method. As a result, the array is obtained as follows:
7

As you know, the standard of user interfaces in messengers today is the same for everyone and they all look like this:

Thus, it is impossible to recreate the standard interface of the messenger by means of Wappler today. But if you make minimal improvements to the dmx.repeatItems function, it will be possible. To do this, you must:

  • In the interface of the repeat component, you need the "reverse" checkbox.
  • In the function dmx.repeatItems, an additional check is made after checking the data type, if the "reverse" setting is selected, then adding elements to the array e is performed not using the push method, but using the unshift method.
    In this case, the array is obtained as follows:
    8

And this is exactly what is required to build the messenger interface.

@George, how realistic is it to add this setting to App Connect?