Join the Webstudio community

Updated last month

Sticky Button Interaction help

At a glance

A community member is trying to create a sticky button that hides when another CTA is present on the screen. The JavaScript code works fine when tested on the Webstudio canvas, but doesn't work when published on the browser. The community members suggest checking the "client only" option and using <script></code> to resolve the issue. Additionally, they recommend setting "client-only true" as a potential solution.</p>

Hi there,

I'm trying to create a sticky button that hides when another CTA is present on the screen.

I'm using some javascript for it and it works fine when i run it on the Webstudio canvas. But when I publish it, it doesn't work on the browser. Any idea why this happens? Is there a better approach for this?
Marked as solution
also probably want to set client-only true
View full solution
J
O
U
3 comments
make sure client only is checked and the script is using <script type="module">
also probably want to set client-only true
Perfect, thank you!
Add a reply
Sign up and join the conversation on Discord