You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I created a minimal example demonstrating the problem. Error message: Uncaught StandardMaterial needs to be imported before as it contains a side-effect required by your code
<!DOCTYPE html><html><head><metacharset="utf-8"><title>Example</title></head><body><canvasid="renderCanvas" width="400" height="400"></canvas><!-- Since import maps are not yet supported by all browsers, its is necessary to add the polyfill es-module-shims.js --><scriptasyncsrc="https://unpkg.com/es-module-shims@1.7.3/dist/es-module-shims.js"></script><scripttype="importmap">{"imports": {"@babylonjs/core": "https://unpkg.com/@babylonjs/core@6.11.1","@babylonjs/core/": "https://unpkg.com/@babylonjs/core@6.11.1/"}}</script><scripttype="module">import{ArcRotateCamera}from"@babylonjs/core/Cameras/arcRotateCamera.js";import{Engine}from"@babylonjs/core/Engines/engine.js";import{MeshBuilder}from"@babylonjs/core/Meshes/meshBuilder.js";import{Scene}from"@babylonjs/core/scene.js";import{Vector3}from"@babylonjs/core/Maths/math.vector.js";constcanvas=document.getElementById("renderCanvas");constengine=newEngine(canvas,true);constscene=newScene(engine);constsphere=MeshBuilder.CreateSphere("Sphere",{diameter: 2,segments: 32},scene);constcamera=newArcRotateCamera("Camera",-Math.PI/2,Math.PI/2.5,15,newVector3(0,0,0),scene);camera.setTarget(Vector3.Zero());camera.attachControl(canvas,true);engine.runRenderLoop(()=>{scene.render();});</script></body></html>
The text was updated successfully, but these errors were encountered:
<!DOCTYPE html><html><head><metacharset="utf-8"><title>Example</title></head><body><ul><li><ahref="https://github.com/BabylonJS/Babylon.js/issues/14034">Issue</a><li><ahref="https://forum.babylonjs.com/t/problems-loading-babylon-via-es-modules/2031/39?u=8observer8">Topic</a></ul><br><br><canvasid="renderCanvas" width="400" height="400"></canvas><!-- Since import maps are not yet supported by all browsers, its is necessary to add the polyfill es-module-shims.js --><scriptasyncsrc="https://unpkg.com/es-module-shims@1.7.3/dist/es-module-shims.js"></script><scripttype="importmap">{"imports": {"@babylonjs/core": "https://unpkg.com/@babylonjs/core@6.11.1","@babylonjs/core/": "https://unpkg.com/@babylonjs/core@6.11.1/"}}</script><scripttype="module">import{ArcRotateCamera}from"@babylonjs/core/Cameras/arcRotateCamera.js";import{Engine}from"@babylonjs/core/Engines/engine.js";import{MeshBuilder}from"@babylonjs/core/Meshes/meshBuilder.js";import{Scene}from"@babylonjs/core/scene.js";import{StandardMaterial}from"@babylonjs/core/Materials/standardMaterial.js";import{Vector3}from"@babylonjs/core/Maths/math.vector.js";constcanvas=document.getElementById("renderCanvas");constengine=newEngine(canvas,true);constscene=newScene(engine);constsphere=MeshBuilder.CreateSphere("Sphere",{diameter: 2,segments: 32},scene);constcamera=newArcRotateCamera("Camera",-Math.PI/2,Math.PI/2.5,15,newVector3(0,0,0),scene);camera.setTarget(Vector3.Zero());camera.attachControl(canvas,true);engine.runRenderLoop(()=>{scene.render();});</script></body></html>
I created a minimal example demonstrating the problem. Error message:
Uncaught StandardMaterial needs to be imported before as it contains a side-effect required by your code
The text was updated successfully, but these errors were encountered: