Inspector Debug code

about:,I changed how to debug the code in the inspector. Is there a way?Ask for help

I found a way,npm run start,Then open index-local.html in the sandbox.However, if you run index.html under the inspector folder separately, an error is reported, and index.js 404

Hi @brightMoon !
I am not sure what exactly do you want to achieve. Do you want to debug BabylonJS source code?

yes, debug the inspector code

Did you already get through this page?

I could quite easily setup my debug environment following these instructions. If you did so and you are stuck at a point, just ask.

Thank you, but Article 6 won’t work

and index.js 404

I am on phone now, I can’t check it for sure, but try local-index instead. I can check it later on my PC, but give it a try.

It doesn’t make sense to run the Inspector alone. You get an 404 because tt is trying to load a test scene from test/index.js which is not present.

You debug the Inspector by running it in a container, for example the Playground, Sandbox or your test scene and invoke the Inspector there.

You have more options. You can start it in VS Code and setup breakpoints

or you can use old plain console.logs and start BJS like this:

you should get this after the compilation is finished:

Navigate to the local PG and invoke the inspector to trigger your console.logs:

Thank you. This will solve my problem