3D model on Mobile shows only on interaction (click or scroll) #4944
Answered
by
Hari-byte-max
Hari-byte-max
asked this question in
Q&A
Replies: 2 comments
-
Interesting - it appears our MV library is not loaded at all on mobile (I can repro the behavior on desktop just by opening chrome dev tools and putting the page in mobile emulation mode). I'd guess some other script on your page is deferring the loading of the MV library until interaction has occurred. If you want that for very high lighthouse scores, you should follow the example we have that does that kind of lazy loading, but with a poster image still shown: https://modelviewer.dev/examples/lighthouse.html |
Beta Was this translation helpful? Give feedback.
0 replies
-
Hey Emmett. Thank you for pointing me in the right direction. I check the code, and I found that Rocket WP option to prevent JS load until user interaction was ON.
Now I turned that option off and model loads immediately. :)
Problem solved
…________________________________
From: Emmett Lalish ***@***.***>
Sent: Monday, November 18, 2024 9:12:43 PM
To: google/model-viewer ***@***.***>
Cc: Haris Nikolovski - Staffel Medien AG ***@***.***>; Author ***@***.***>
Subject: Re: [google/model-viewer] 3D model on Mobile shows only on interaction (click or scroll) (Discussion #4944)
Interesting - it appears our MV library is not loaded at all on mobile (I can repro the behavior on desktop just by opening chrome dev tools and putting the page in mobile emulation mode). I'd guess some other script on your page is deferring the loading of the MV library until interaction has occurred. If you want that for very high lighthouse scores, you should follow the example we have that does that kind of lazy loading, but with a poster image still shown: https://modelviewer.dev/examples/lighthouse.html
—
Reply to this email directly, view it on GitHub<#4944 (comment)>, or unsubscribe<https://github.com/notifications/unsubscribe-auth/BNAY4L5SQCFJQVE5CMLZ67L2BJC3XAVCNFSM6AAAAABR7GB4PGVHI2DSMVQWIX3LMV43URDJONRXK43TNFXW4Q3PNVWWK3TUHMYTCMRZGY2DKNI>.
You are receiving this because you authored the thread.Message ID: ***@***.***>
|
Beta Was this translation helpful? Give feedback.
0 replies
Answer selected by
elalish
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
I created this simple scene to test implementation of .glb model in to a WordPress website.
https://staffelmedien.ch/home-page-test
On the desktop model shows on page load and work as intended. On mobile, page loads (background and text), not sure if model is also loaded this time, but model will not show, until user click on the screen or scroll.
Can anyone help me why is this happening?
Beta Was this translation helpful? Give feedback.
All reactions