Some of the dynamic values are not working on the published page or the play button, but if I test it using the interactive toggle switch, it works.

I’m trying to test our page using the Play button (Preview current artboard) or view on a website (Published), but some of my codes/dynamic values there are not working, specifically &&, ||, or a simple dynamic value to tick a box form field.

But if I test it using the interactive toggle switch it works…

**The grayed out Complied tick box should be checked if all the Yes buttons are checked.

Hello @jd-obera, Please also share your project id so we can investigate further.

@sarah_ahmed w8CxGQw9xuAwL6EFmdnat9

The problem seems to be that you are setting the dynamic value on the initialValue prop (and not a value/checked prop). As a result, even after the switches are turned on, the Compiled checkbox stays unchecked.

I would expect the compiled Checkbox to have a value or checked prop instead, where the dynamic value should be set. Are you using a custom code component for the Compiled checkbox?

The thing is, this is a form field, that is why there’s no value/checked prop.

(Any updates here? I’m planning to get a subscription if this works here… and discontinue if it will not work…)

Also, you could use a Plasmic checkbox component instead of a form field of type checkbox. There, you have a checked prop available where you can set the dynamic value.

got it, but how can I move that data to the form?

I’m just wondering why it works in interactive view and not on the web or the green play button…

Yes, I’m using && to tick the checkbox if the all the switches are turned on.

The canvas is always in sync with the props you set on component. InitialValue is just another prop for it. Interactive mode lets you update the dynamic value of the initialValue prop, and as a result the new prop value is immediately reflected on the canvas.

The Plasmic checkbox checked value is exposed as a state (you can find page states in the Page data tab on the right, under “State variables”). You can use that state when submitting the form

1 Like

got it, I’ll try it, and I’ll update here, thanks!

I’m using a supabase table, I can’t see how that state will help input my check mark on a specific column. Can you tell me how can I “use that state when submitting the form”? Thanks!

I still can’t work it out, maybe for ease of use just add “Is checked” at the form field (checkbox) too?


Yes, I have created an issue for this, but in the mean time, you can use the Is Checked field in the supabase create row interaction by using something like the following in the "Fields:


Thank you!