Find your people. Pick a challenge. Ship something real. The CreatorCon Hackathon is coming to the Community Pavilion for one epic night. Every skill level, every role welcome. Join us on May 5th and learn more here.

How to check device type is mobile on client side scripts

Pallavi26
Kilo Explorer

Hello,

Can anyone tell me what function to use to test device type == mobile in client side script? Like for example we use gs.isMobile() to test devices is mobile on server side script.

1 REPLY 1

Anurag Tripathi
Mega Patron

You can use gs.isMobile()  on a display BR and set a scratchpad variable based on this. In the client script just read that scratchpad value 🙂

-Anurag