Share feedback, ideas and get community help

Updated 5 months ago

Can't handle some structures

At a glance

The post indicates that the system cannot handle arrays of arrays, and instead converts the inner arrays to strings. A community member has added documentation about this issue, explaining that the system only supports certain valid value types. Another community member suggests using JSON.stringify to save complex content, such as objects, as text, and then using JSON.parse to dynamically parse the variable back into an object when needed.

Useful resources
For example, it can't handle array of arrays.
It ends up converting the inner arrays to a string.
V
B
4 comments
I've just added a section about this in the documentation: https://docs.typebot.io/editor/variables#valid-value-types
If you really need to save a complex content into a variable, for example an object, you can use the JSON.stringify function to convert it into a text. And whenever you are using the variable, you can dynamically parse it back into an object using JSON.parse in an inline format:

Plain Text
{{=JSON.parse({{My object variable}})=}}
Add a reply
Sign up and join the conversation on Discord