JS script doesnt works on WIX

Hello every one, i try to add the model viewer script to my wix site and some why it doesnt work.
Here the code i add to head:

<script type="module" src="https://unpkg.com/@google/model-viewer/dist/model-viewer.js"></script>
<script nomodule src="https://unpkg.com/@google/model-viewer/dist/model-viewer-legacy.js"></script>

And then i add this to HTML iframe module:

<model-viewer src="shared-assets/models/Astronaut.glb" alt="A 3D model of an astronaut" auto-rotate camera-controls background-color="#455A64"></model-viewer>

That works perfect on regular website but not on wix…
Anyone can help me ?

Are you adding the first block of code to a new custom tool in Tracking Tools and Analytics and then adding the second block of code in a html iframe on the page where it is needed?

Also, as stated in this page from Wix about using code in iframes, that Wix won’t provide support for any code that has come from a third party provider.
Wix cannot provide support for external codes that were not created or tested with Wix.
If you are experiencing an issue with your code snippet, please contact the provider directly.

Plus, you will also note that on the above linked page that iframes are sandboxed if you are just using the free version of Wix and will only not be sandboxed if you have a premium Wix site.

So, if you are having issues trying to integrate this into Wix then you might be better suited going back to the third party code provider and asking their own support how to integrate it into Wix so that it works and whilst there, you can double check with them that it is supported in Wix as not everything will be allowed.