List Shifter: Reverse, Rotate, Swap and ITERATE (Loop) Over Bubble Lists | Now Part of Floppy

Hey @gavin1, I’m not finished with giving you a VERY detailed bit of advice here, but didn’t want you to have to wait. When I write detailed stuff like this, I want to make it broadly useful, but that takes a lot of time, so here’s an in-progress version of my advice for you…

Ah, yeah. So, you need to wait until those actions are done. Now, a possible oversight on my part with the SORT action is that I didn’t include an event for “SORT Complete”. (That would be a friendly thing to do and so I’ll address that in a future update.)

We can, in fact, use List Shifter itself to work around this limitation. But first, let’s discuss event-driven programming in general. Bear with me as this will be helpful.

(You’ve probably noticed that List Shifter has a bunch of events that it fires so that we can take action on things in the right order. You can see them like this:

)

We use these events to know when it is safe for us to do stuff. One of the most important of these events is List Shifter Initialized/Updated. You might be tempted, for example, to shuffle the deck not via an explicit button press, but automatically on page load.

Well, if you try to fire one of List Shifter’s actions at it before List Shifter is fully initialized (meaning that the plugin is fully initialized and the initial value of the Original and Shifted Lists has been established), you’ll get an error (really more of a warning). So instead of (or in addition to) firing on “page loaded”, we instead would fire those actions when List Shifter Initialized/Updated. So, instead of this (button press):

We could do also or instead do (shuffle the deck in ListShifter Nano Sort as soon as it’s ready to rock):

ASIDE: Now you’ll see what I did here is copied each of the workflow steps from the Button press workflow to this new workflow. If shuffling the deck is something I might do a lot I should probably move that to a custom workflow, right so I don’t have to maintain that in two different places.

So here’s what I should really do:

And then my Button press and Initialize workflows can just be like:

OK, now if we test this right now (preview our page), we may see the debugger report some errors (again, really just warnings in this case) that (1) we tried to run PROCESS List on List Shifter Nano Sort, but our list of items was empty so PROCESS did not run and (2) that we tried to do SORT on List Shifter Deck, before List Shifter Deck was initialized.

These warnings appear both in the debugger and in the console:

Why did we get these warnings? We waited to run PROCESS List on Nano Sort until it was initialized and the subsequent SORT action (which, remember, sorts the list in DECK, using the sort order we stored in Nano Sort’s Processed List).

So, why would this happen? Well, you’ll recall that List Shifter Nano Sort’s “list to shift” gets its value from one of List Shifter Deck’s outputs:

When the page loads, ListShifter Deck’s Original List will be empty until List Shifter Deck finishes loading its list. (And remember that the source of that list is a Search and so this takes a small amount of time.) So List Shifter Nano Sort actually reaches its Initialized state (and fires an Initialized/Updated event) before List Shifter Deck. (Because it takes us almost no time to load the empty list into a List Shifter.)

But then, when List Shifter Deck finishes loading its list (Search for Cards…) and the value of its Original List changes, List Shifter Nano Sort automatically updates (reinitializes itself) and fires its Initialized/Updated event again.

:point_up: This is important to know and it’s super useful! (We are going to use this feature to know when our deck has been sorted, even though that meanie Keith didn’t give us a “SORT Complete” event!)

Anyway, once List Shifter Nano Sort updates the second time, our PROCESS and SORT actions succeed and we can actually see that this happened in the page:

And of course we only notice these warnings if we are running the debugger and/or looking at our console and they “ain’t hurtin’ nobody” as I like to say. It’s not really a problem that we tried to PROCESS and SORT before things were totally ready as – in this case – those steps are going to run automagically once things are ready and we get our intended result. (Which, in this case, was automatically shuffling our deck right away when the page loads.)

If we wanted to suppress these warnings, we would put one extra condition on our When Nano Sort Initialized/Updated workflow, so that we only attempt to shuffle the deck when List Shifter Nano Sort actually has any items in its list:

:point_up: There are several ways to test if a list has no items. We can check if the list’s count (length) is greater than zero. Or, as I did here, we can check if the list’s :first item is not empty. The difference between these is more or less academic in most use cases. (You might also notice that List Shifter has an output called “Item Count”… we could check that this property is > 0 but note that it won’t give us the desired behavior, because List Shifter's Item Count actually goes positive before the the items in the list are actually loaded! (This is not a bug, but a very useful feature in certain use cases.)

Now our page won’t throw any warnings at us. The reason this works is we now only attempt to shuffle when List Shifter Nano Sort’s Original List has items in it. And… since the source of List Shifter Nano Sort’s Original List is List Shifter Deck’s Original List we can be assured that Deck is initialized and has items in it as well. :wink:

OK, so back to dealing cards!

Now, what you are attempting to do is to shuffle the deck and then immediately “deal” three cards when a certain button is clicked. (That is, this is what the workflow you screencapped is doing.)

And, as you discovered, the whole PROCESS → SORT rigamarole is not finished when Step 3 of your pictured workflow attempts to grab cards from ListShifter Deck’s Shifted List. So we need to trigger that “dealing” from some other event.

Let’s use what we just learned above to accomplish this. We’re going to put another List Shifter on our page and this one we will configure to copy List Shifter Deck’s Shifted List. And so, this List Shifter will Initialize/Update whenever List Shifter Deck’s Shifted List changes.

Note: Again, I’m working from my original example about sorting that I created for you. It looks like you decided to go with the “alpha” sorting technique which I’m sure you reconfigured to use just a single List Shifter. Don’t get confused by the fact that my demo page has 2 (now 3) List Shifters.

Here’s the new List Shifter, which for now I’m going to call “Shuffled Deck”:

And now I have an event that fires whenever List Shifter Deck’s Shifted List changes and I can take actions there:

Now, just like in the example above, this event will fire on all changes. But we’re only interested in certain ones – we’re only interested in this change when List Shifter Shuffled Deck’s Original List has items in it.

Also, we are only interested in this event if List Shifter Deck’s Shifted List is different from its Original List. (That is, when the list has been “shuffled”!) List Shifter has an output called “List Shifted” (I know – this is a little confusing vis-a-vis “Shifted List”). The “List Shifted” output is a boolean (yes/no) that goes to “yes” if Shifted List is different than the Original List. (And it will go back to “no” if they later become the same again.)

Cool. So we can do:

And we could do something in the workflow to test out whether this detects the condition we want. You could display an alert or make something visible or whatever, but I like to use Debug Buddy, List Shifter’s companion action to just write something out to the console to let us know something happened:

Remember that in my demo page, the Deck now gets shuffled automatically when we load the page and so we should see this event fire. And we do:

In fact, we see it fire twice (the little “2” in a circle means the console printed this exact same console message twice). I don’t have a good explanation of that at the moment, except that plugin loading and initialization in Bubble is a bit weird, especially when we are loading lists.

This doesn’t really cause us a problem, because we’re actually going to add a third condition to that “When LS Shuffled Deck is Initialized/Updated” workflow, but…

If that bugs us (or if that potentially is a problem), we could reconfigure List Shifter Shuffled Deck (the yellow one) such that it just stays empty until List Shifter Deck has been initialized and “Deck’s List Shifted” value has gone to yes. To do that, we’d empty out the “List to Shift” entry in the move it into a condition:

Now we get the behavior we want on load. Here’s what we see on page load:

And, now, if I click one of the shuffle buttons, we’ll see this same event fire and we can confirm that the contents of List Shifter Shuffled Deck are, in fact, the same as the newly shuffled deck (held in List Shifter DECK’s Shifted List) and the SORT action is, in fact, complete when this event fires:

OK, so now we have an event that fires whenever the deck has finished shuffling. And so you might have noticed that now I have a button labeled “SHUFFLE and DEAL ME THREE CARDS”.

What we’re gonna do when this button is clicked is:

  1. Set a state that tells us, “Hey, we are now shuffling and dealing 3 cards.” This can be a simple yes/no that we set to yes.
  2. Trigger the Shuffle Deck workflow.
  3. Listen for when the LS Shuffled Deck and the state we set in step 1 is “yes”.
  4. When we hear that we will “deal 3 cards” ← we still haven’t defined what this means, really
  5. Set our state back to no so we know we are not dealing anymore.

Now we could create a custom state for #1 anywhere on our page, but List Shifter has a custom state built right in, so we might as well use that.

What I’m going to do is configure the List Shifter Shuffled Deck’s “process output type” to be boolean (yes/no). (Process output type controls the data type of List Shifter’s 4 auxiliary outputs – Processed Result, Processed List, Custom List, and Custom Value.)

And now that List Shifter’s Custom Value becomes a yes/no state that we can set on-demand just as we would with a custom state. So we’ll build our workflow for what happens when the SHUFFLE and DEAL button is clicked:

  1. Set our Custom Value to “yes” (we also have to “publish” this state so we can read it at the List Shifter’s outputs… if we don’t publish it, it’s still available to List Shifter internally – i.e., in the PROCESS List action – but it won’t be available to normal Bubble workflows. (There are many uses for this feature that I won’t go into here.)

  1. Trigger the Shuffle Deck workflow

  1. Build my workflow for what happens after list sorting is complete. Note that I add 1 condition to the conditions on this workflow – it should only fire if LS Shuffled Deck’s Custom Value is yes:

  1. Now I get to decide what “dealing 3 cards” means. In your example, you are taking 3 cards from the shuffled deck and creating/making a “Hand” object in the database. I guess you do that because this is a multiplayer online card game or something?

We don’t have to make something in the database. We can of course just create a “hand” in the page. Since a hand is really just a list of Cards, we can use either a custom state or List Shifter(s) to hold those cards.

Of course, if we are creating a game, we might also want to know things like “which cards are still available to draw from our deck?”

So what I’m going to do is just represent the hand as a list in the page, using List Shifter. I’ll create a List Shifter Player’s Hand and set both its Data Type of List and Process Output Type to be of type Card:

I’m not going to set a source for List to Shift, because I’m just going to use this in lieu of a custom state (building my list in the List Shifter’s Custom List). So for my drawing cards workflow, I do:

And, at this point, I have a thought: I’m drawing cards from List Shifter Shuffled Deck’s Original List (note, I did not pick List Shifter Deck’s Shifted List… even though these are [at the moment] identical lists)… If I really am building a game, I’m going to need to know how many cards have been dealt. So I should also update another List Shifter to keep track of that.

So I make one – it’s just a clone of the “Player’s Hand” shifter as it needs the same setup, I just change its name to Dealt Cards:

And then in my workflow (which I’m going to rename as well - to “Deal Cards” because the auto-description is so fugly):

:point_up: so here, instead of just setting the list to a new list (the three cards we deal), I’m adding this list to the list that’s already there. Now, the first time through, LS Deal Cards’s Custom List will be empty, but multiple times through, it’ll have values. So the way to “push a list on to a list” in Bubble is to :merge the lists.

… to be continued… but you should have the idea by now…

Wow. That is a huge post. Thanks!

I think where we get to (putting aside the shuffle on page load bit) is:

  1. User clicks Shuffle and Deal
  2. LS Shuffled Deck custom value set to “yes” to indicate dealing is happening and
  3. Shuffle is triggered which ultimately passes the shuffled deck into the LS Shuffled Deck
  4. The LS Shuffled Deck initialised/updated workflow identifies that the deck has been shuffled and that the custom value is yes and
  5. Sets the custom value back to “no” and
  6. Creates the custom list in the player’s hand LS with the first three cards of the shuffled deck. (I’ve swapped this out for the update database action but it works the same).

Great work. Definitely worth another contribution to the coffee/cigarettes fund.

Dammit. I spoke too soon. In my app, the database usually gets updated when I click on the shuffle and deal button, but not 100% of the time. About 10% of the time, the action to update the database doesn’t seem to fire. Would you mind including a step in your demo app to update the database?

Hey Gavin, what’s your Create a New Thing dialog look like now? The issue you are likely running into (if you are purely copying my example from https://list-shifter-demo.bubbleapps.io/version-test/mapped-sort-shuffle-cards?debug_mode=true is that List Shifter actions “Set Custom Value” and “Set Custom List” are, in fact, different from setting a Bubble custom state (i.e., doing action Element > Set State).

It turns out that we can count on Element > Set State to be synchronous in a Bubble workflow, but LS Set Custom Value and Set Custom List run asynchronously. What this means is that, downstream of the LS Set action, we cannot actually guarantee that the values are updated before we try to do something with them in the workflow.

(This is one difference between native Custom States and List Shifter custom states that I either had not fully realized, or that I had forgotten.)

So, as an example, this workflow can create a “Hand” object whose list of Cards is empty:

:point_up: Step 3 updates List Shifter “Player’s Hand…”'s Custom List with three cards from the Shuffled Deck. But the workflow does not wait until that operation is complete. So when we get to Step 5, and reference “Player’s Hand’s Custom List” there is no guarantee that the this list is populated yet and so the Hand object may (and usually is) have an empty list of Cards.

So, instead in Step 5, what we should do is just use the source expression for Step 3, rather than referring to the Custom List (which, again, is probably not updated by this point).

That is, Step 3 sets our Custom Value like this:

And so I’ll just use that expression in Step 5:

(Another obvious workaround would be to change our workflows in this example to use native Bubble custom states rather than List Shifter Custom Values/Custom Lists.)

I do continue to wonder, however, why it is that you want to create an object representing the “Hand” in the database. If you’re building some sort of game, you can manage its state entirely in the page without interacting with the database (except to fetch the initial deck of cards, of course).

If you visit the shuffle example page now, you’ll see there’s all the makings of a card game. The game is stupid (all you can do is draw cards and optionally discard them until we run out of cards!), but all the info is there to save the state of the game in the db, should you desire to.

The one “tricky” bit I did is I’m automagically managing List Shifter Shuffled Deck to represent the remaining cards in the deck. To accomplish that, I changed its List to Shift to be this:

How this works is that, when we deal the player a card (or cards), we deal the card from the top of this list. But we also take that same card and add it to List Shifter Dealt Cards’s Custom List.

And, in doing so, we cause this List Shifter to update itself, removing any of the dealt cards. So, whenever this list has no items, the game is over. (There are no more cards to draw!)

I’ll look through this properly tomorrow (bed time here in the UK). It’s a multi-player card game I’m building. My understanding is that I need to update the database so that all players can see the same cards. Of course I might be wrong.

Actually I don’t worry about undealt cards. I deal them all upfront in the background and have conditions to reveal them at the appropriate time.

I’ve moved the ‘dealing’ variable into a standard custom state and that seems to have fixed it. (I wasn’t using the LS Custom list).

To update the database, I’ve just done this to keep it simple. But now I’ve got this working, I might do something more sophisticated.

image

I’ve clicked the shuffle and deal button 50 times and it updated the database with new cards every time.

Thanks for all your help. You’ve gone above and beyond! If I ever get this thing launched, I’ll come back and reward you properly.

Glad you got it sorted, @gavin1! One thing that may help you in future: I am working on Server Side Action versions of the List Shifter actions and so you’d be able to do things like highly random sort and Process List in backend workflows.

That’s a pretty near-term thing and when I release that, I’ll also release an update to List Shifter with the “missing” SORT Complete event and some other new stuff.

@keith Loving your videos and hoping your plugin will help me out, not sure if it’s the right scenario for it. Can you help me identify if it is, for the following scenario? :slight_smile:

I have a list of names (list X) and I want to create a new thing (Y), which is also text, that contains the names from “list X”. But the makeup of the new thing (Y) will be contingent on the number of items list X contains.
The rules would be:

  • If list X item count is 1 then add sentence 1 to new thing Y.
  • If List X count is any number > than 1, but not the last item in list X then add Sentence 2 to new thing Y and continue adding Sentence 2 over and over until it’s through the 2nd to last item from list X.
  • If item is last item in list X then add Sentence 3 to new thing Y.

Again each of those sentences (1,2, and 3) contains a name from List X. And I’m guessing since I need to add iteratively to New thing Y it will have to be a List ? Just don’t want to display all the commas a list would display on the UI.

Let me know if that’s super confusing and I’ll stop speaking in generalities.
Thanks!

I sort of understand what you’re trying to do, @Blake, and you can do this type of concatenation with List Shifter’s PROCESS List action.

However, you can also do it in vanilla Bubble. If I understand you right, you have a list of texts that represent sentences. Lets call it X. And this list (if we were to visualize it in a text element) looks like:

This is sentence one., This is sentence two., This is sentence 3

But you don’t want to see commas. You just want a space there.

Use the :join with operator to select a different joining string. The default is comma, but you could select space instead. Build the expression:

X:join with " "

And now you’ll have:

This is sentence one. This is sentence two. This is sentence three.

Sorry, I didn’t explain this well and or it’s just a confusing scenario. The comma’s aren’t that big a deal, it’s conditionally creating a paragraph based off a list that already exists in the DB which I can’t get done.

The idea is to tell a story about your parents:
User’s parent_list: Mom, Dad, Grandma (could be any list combo of relations)

Need to create another thing or another list (which one I’m not sure yet call it “Thing Y”)
but the idea would be:

From each item in “parent_list” create thing Y so that your end result would be:

  1. John was raised by a great [Mother], + 2. and a great [Father], + 3. and a great [Grandma]. From these parents he grew up loving life.

Any person could have any number of parents or people that raised them so the paragraph needs to be created to dynamically accommodate any number of scenarios. But you could see that if there were 4 parents instead of 3 as above then sentence 2 and 3 would be identical (with exception of the DB [parent relationship] dynamic field that get’s added (which is indicated with [ ] above).

If there was a way to take that “parent_list” and use the bulleted list of rules (in previous post) to create thing Y I think it could happen. But I’m pretty sure it needs iteration functionality because you’d have to do it “for each” item in “parent_list” but just slightly different given it’s position number in “parent_list”

If you can get your head around that and offer a suggestion, then beyond impressed, I’d be very grateful.

Yeah, @Blake, your use case isn’t hard to understand and you’ve now explained it quite well. You can do this in the page with List Shifter (specifically, by using PROCESS List to forEach over your list).

Note that you can’t (yet) do this as a backend (server side) workflow. I’m actually working on PROCESS List as a server-side action, and it works (ish) at the moment, but needs more testing.

Now, what you’re trying to do here might be a little bit complicated to do with PROCESS List and might take multiple steps.

But my suggestion would be that you try and then, if you make no progress, share the editor to your attempt with me. You might have noticed that I sometimes answer folks questions like this by building a demo that’s essentially their whole damn app and I don’t have time to do that at the moment. :wink:

The hard part of that is building the database junk and actually having something to operate on.

So give it a shot first and then you can point us to either your (hopefully!) successful attempt or (in the event of failure) I can just get into your page and actually show how you’d do it in context.

Here’s an intro to PROCESS List (covering just the very very basics, but likely enough to get you started):

Check it out:
https://vimeo.com/361188099

Note that PROCESS List has operations such as concatenate (and with texts you can just use the + operator as well to concatenate).

Advanced uses of the PROCESS List action can be somewhat difficult to get your head around (and there are many capabilities – like “set PROCESS List field of interest” that there’s no way to document well except by example), but I actually think you can work this out after watching the intro video linked above.

Let me know how it goes! -K-

Just pushed List Shifter version 1.9.19! New in this version:

  • Adds a SORT Complete event so you can detect when the SORT List action has completed (it was stupid List Shifter didn’t have this before, sorry).

  • Enhancements to SET Custom List and SET Custom Value Actions: In addition to just setting a value you can now optionally INCREMENT the value (allowing you to perform basic arithmatic on the Custom Value without having to publish it). Similarly, in SET Custom List, you can CONCATENATE the Custom List with some other list (or even just a single item), allowing you to push new items to the Custom List without having to publish it. (These are useful for iteration speed freaks.)

  • Additionally, the SET CL and SET CV actions now can optionally trigger an event when they are complete. (This is useful as these actions are asynchronous. More on this in a future video.)

  • SET Process FIELD of Interest Action now allows you to define up to 3 fields of interest for your next PROCESS List action (and these can be accessed from the operand and operator dropdowns in PROCESS List), instead of just one.

  • Surely some bug fixes to various PROCESS List operations and a couple of new operand and operator choices (the aforementioned “fields of interest” and the useful values true, false, 0, 1 and perhaps some new functions I’ve forgotten about).

Aside: I had intended for this version of List Shifter (or perhaps a companion plugin) to include a server-side version of PROCESS List. That’s something that’s still to come, pending resolution of a bug in Bubble’s Server Side Action API that I managed to tickle.

As a reminder: List Shifter is Karma-Ware… If you love List Shifter, show your support at https://grupz.com/karma!

Hi Keith,

List Shifter is a really impressive plugin! I’ve been testing it out together with the Leafy map plugin in order to display records on a map. For some reason all of my List Shifter workflows seem to work perfectly whenever a User is logged in, but whenever the User is NOT logged in, the event “When a List Shifter is Initialized / Updated” appears not to fire. I’m wondering if you can offer any suggestions / thoughts on what might be causing the problem.

I’ve attempted to debug this every way I can think of, but I suspect I’m either misunderstanding how List Shifter events work in sequence, or else I may have stumbled on some sort of bug.

Here’s the basic context: A page in my app (labeled city_records_event_map) includes both a Leafymap as well as a Repeating Group, which is used to display the records that match the markers displayed on the map, like so:

I use a single List Shifter element to populate the markers on the map, as well as the RG. Whenever the BEGIN ITERATE step runs, ListShifter finds all records that match a specific set of parameters, including lat/lon values within a hidden polygon on the Leafymap, as well as the category of records selected by the user via the right sidebar menu (i.e. , “crime”, “building permits”, or “city service records”).

I set up different workflows so that when the user selects different categories to display via the sidebar menu, List Shifter will remove records from the map and RG from the previous category, before adding records for the new category (based on the LS custom state “action_mode”, which can be set to “add_markers” or “remove_markers”). When the page loads initially, I set custom states to pass in default parameters for the first run of the List Shifter search.

The workflows all appear to run correctly whenever the user is logged in, but for reasons I cannot figure out, whenever the user is NOT logged in, the List Shifter does not appear to fire the “Initialized/Updated” event. I’ve tested this by making sure the exact same address is being used as a search parameter when the user is logged in, as well as when he isn’t. All of the other query parameters appear to be set correctly as well in both cases.

I tried adding a 5000ms pause between the “Initialized/Updated” event and the BEGIN ITERATE step, but that does not appear to have any effect (other than delaying the workflow results).

I’d appreciate whatever thoughts / suggestions you might have whenever you get a chance - I’m specifically wondering if I’m simply neglecting to sequence the List Shifter workflow steps correctly.

If it helps, here’s the link to my app’s editor: cyvil-beta | Bubble Editor

Thanks!

There shouldn’t be any difference, @eric.k. If the List Shifter is visible, it will throw this event. Could it be you’ve got it located in some group which does not show for unlogged-in Users?

Hi Keith, thanks for the prompt response. I checked and the List Shifter is not located inside a hidden Group.

When I run the Bubble debugger, I notice that the “Initialized / Updated” event appears to fire 4 times in a row when the page is loaded. I’m wondering if that might be causing the issue, and if so, whether there is a way to prevent that from happening? The final step of my “When page is loaded” workflow sets 3 custom states on the List Shifter element (because each of those states represents a parameter used in the search that populates the “List to Shift” field, per the screenshots below).

Setting custom states of List Shifter upon page load:

Passing custom state values into List Shifter search as query parameters:

By setting 3 custom states on the List Shifter element, am I causing it to fire the “Initialized/Updated” event 3 times consecutively, and if so, is there a way to have it only fire once?

Just closing the loop on this FYI - turns out the problem was related to the 'Privacy" rules that were set for the records I was trying to display - I had neglected to make sure that non-logged in Users had the appropriate permissions to view them.

Thanks again for List Shifter, it’s a great plugin.

Hey List Shifters! I just pushed version 1.9.20 of List Shifter. This is purely a bugfix release and it doesn’t add any new features. However, the bugs it fixes are pretty important if you’re into the PROCESS List action.

Basically, some of the Process List operators that work on arrays did not work correctly with Things, forcing you to do stupid workarounds. Specifically, this release fixes an issue with the following Process List operators which would not return correct values if the array “x” and the individual item “y” were Things:

  • Array x.indexOf(y)
  • Array x.includes(y)
  • Array x.count(y)
  • Array x.lastIndexOf(y)

Now (for example), if “Array x” is a Thing (like a list of Users) and you attempt to indexOf “y” (a single User), you’ll get the correct answer (instead of the operator always returning -1).

On the new features front, Bubble recently fixed a bug that was preventing me from introducing a server side version of PROCESS List which I’ll be releasing in the near future after a bit more testing. (This will probably be a paid plugin, but priced at something like $10 once. More on that soon.)

-K-

Great plugin Keith.

Am I missing something or can I not use List Shifter to write all fields of a RG which links to multiple data types (tables) into a new table?

Hey @dehacked79, I’m not quite sure what you mean? Note that, in Bubble, there is no concept of an in-page or temporary object. There are only your custom datatypes (which Bubble calls “Things”).

Things can only be created by interaction with the database via the “create/make changes to/delete a Thing” workflow actions. And these operations can only be done via the Bubble programmer. Plugins cannot create, modify or delete Things. (There’s no API for that, which is likely intentional.) Plugins can only read data from the database that is sent to them (as when you feed List Shifter with a “Search for… some Thing”).

Additionally, the only data types a plugin can output are the built-in data types and your app data types (the Things you create in your database). So there’s no way for List Shifter (or any other plugin) to dynamically create some new object.

So what you can do is use a series of List Shifters to hold and/or create parallel lists of Things, primitive data types, etc. and then – if you need to turn those into some objects stored in your database, you can either (1) use List Shifter’s iterate feature to sequentially create some new objects while in the page or (2) pass these lists to a recursive API workflow or API workflow-on-a-list to create those objects.

I show an example of this in this video about shopping carts: 📒 What is the best way to publish a list of objects to bubble?

-K-

And, before anyone mentions it: I just pushed List Shifter v 1.9.21, which fixes an issue that caused the preview icon to not draw. (derp)