About the Developer Category

A place for Tulip Developers to ask more advanced questions about APIs, custom widgets, hardware and software integrations, and Node-RED

Advanced Tulip features that fall into this category:



1 Like

Good morning,

first of all i want to congratulate you for this new feature. It is the part that was missing in the past.
And i have a small question. Could you enable “anonymous” objects and object arrays as input propertys? With this we could build widgets that are not hard coupled to datatype definitions from tulip. I think that something like an “SerializeToJson” and/or “DeserializeFromJson” in the normal Tuliptriggers can do the Job.

I have found the same thing, because prop types are static, it forces you to make duplicate widgets (with slightly different props) that otherwise could be unified. I could see anonymous pros that you could then check the type of in JS and act accordingly. I will talk to our developers about the feasibility of this.

Keep the great ideas coming-
Pete

1 Like

@nils.husemann You do hit on something we also found in our hackathon, one way to get dynamic input is to pass a json into the widget on a text prop, and decode it in javascript, kinda a pain to hit on the trigger side, but an option.

The usecase where we found this nice was making dynamic forms with a custom widget, pass in a json and it creates a form with labels and inputs. that json could be stored in a table to make the code even more modular.

Pete

Yes. My usecase would be to build an generic Table view with advaced functions. Do you have already build an workaround to build Json on the Trigger side? And is it planned to enable some function like this in the future?

Hi @Pete_Hartnett,

I would love to have some kind of an enum based switch (dropdown) as a property.
So you could use this to change some specifications of the widget by choosing a setup from that enum list, instead of creating several custom widgets.

For instance you could make a banner widget and choose the type of banner (like color, image, default text, size…) by name in this dropdown .