Hi, am a complete three.js beginner -
and maybe this is a fundatmental missunderstanding,
but:
can you help me what’s wrong with this code (placed in a wordpress page),
the javascirpt code in the type="module part will not be executed:
thank you ! (sorry for the fomatting on my old pc -
i had to insert a blank before each “script”- tag and to XXX-out the links)
<php get_header(); ?>
<?php get_footer(); ?>
< script src=http://haho.dreampress.at/wp-content/themes/twentyfourteen/js/three.min.js>< /script>
< script type="module">
$j("#main").append('< canvas id="canvas" width="500" height="500" style="background:pink;">< /canvas>');
import * as THREE from 'XXXhttp://haho.dreampress.at/wp-content/themes/twentyfourteen/js/module.js' ;
import {OrbitControls } from 'XXXhttp://haho.dreampress.at/wp-content/themes/twentyfourteen/js/OrbitControls.js';
import { OBJLoader2 } from "XXXhttp://haho.dreampress.at/wp-content/themes/twentyfourteen/js/OBJLoader2.js";
import { MTLLoader } from "XXXhttp://haho.dreampress.at/wp-content/themes/twentyfourteen/js/MTLLoader.js";
import { MtlObjBridge } from "XXXhttp://haho.dreampress.at/wp-content/themes/twentyfourteen/js//MtlObjBridge.js";
function main()
......
main();