Wordpress template integraiton

Hi,

I have a project that I have exported as .hyperesources proect. I've uploaded this to the WordPress theme folder and checked the .js URL and that loads correctly.

However when I add the code to the WordPress template it doesn't display anything.

<div id="discover_hype_container" class="HYPE_document" style="margin:auto;position:relative;width:100%;height:100%;overflow:hidden;">
	<script type="text/javascript" charset="utf-8" src="https://url.com/wp-content/themes/themename/js/discover_hype_generated_script.js?63338"></script>

Any idea what I'm doing wrong?

Thanks.

Do you see any errors in your browser's console log? :thinking:

Since you're loading the Hype project as part of the template, I'm not sure if the error is on the WordPress side of things. I haven't actually edited the template files to add a Hype project. I usually just add a block for such things.

I recommend setting a height for your document instead of using 100% as the height. If you use flexible layout, and insert a document into a WordPress template, it typically does not have a set height, so it appears as zero pixels tall.

Thanks for your reply.

The browser console now shows an error :
Loading failed for the with source “URL.com - MediaOptions

I moved the .js file into the theme js folder. I can see the other scripts within that folder if I copy their URL but not the Hype script.