Using VS Code (or other code editors) with PlayCanvas

I would like to use VS Code for scripting instead of the PlayCanvas code editor. How can I achieve that? Are there any drawbacks?

The main reason I want to do that is so that I can write my code in ESNext and compile it to ES5. If there is a way to do that while staying in the PlayCanvas editor, that would be great.

1 Like

I don’t believe that’s possible using the current scripting system, unfortunately. You’d need to use the legacy scripting system to do that. See https://developer.playcanvas.com/en/user-manual/scripting/legacy/

A bit of a workaround but may be inline with a workflow that you are familiar with.

@whydoidoit has created a template project for using ES6 via Babel and WebPack to build PlayCanvas projects.

1 Like