three.js dev template - module

by GnanaSai

HTML

<script type="importmap">
	{
		"imports": {
			"three": "https://raw.githack.com/mrdoob/three.js/c9ee853e95ac62ff67450fd239d655121ce54829/build/three.webgpu.min.js",
      "three/tsl": "https://raw.githack.com/mrdoob/three.js/c9ee853e95ac62ff67450fd239d655121ce54829/build/three.webgpu.min.js",
      "three/addons/": "https://raw.githack.com/mrdoob/three.js/c9ee853e95ac62ff67450fd239d655121ce54829/examples/jsm/"
		}
	}
</script>

CSS

body {
	margin: 0px;
}

JavaScript

// https://github.com/mrdoob/three.js/issues/29526

import * as THREE from "three";

console.clear();

var renderer = new THREE.WebGPURenderer(),
	scene = new THREE.Scene(),
	camera = new THREE.PerspectiveCamera(30, innerWidth / innerHeight);

// these two lines are not needed for the issue
// they are needed when trying the code with r167
camera.position.set(0,0,10)
document.body.appendChild(renderer.domElement);

scene.add(new THREE.AxesHelper());

renderer.renderAsync(scene, camera);