Pre-requisites
- VS Code is installed.
In VS Code
-
Enable the co-pilot agent mode in settings.

-
Open a new folder for your app.
-
Use
CMD + CTRL + Ito launch the chat window. -
Change the chat from Ask to Agent.

-
Provide a context/prompt to the copilot chat. For example, we want to build a 3D scene using three.js:
Use three.js to create a 3D scene below. 1) A carpark with 10 spaces. 2) Simulate car coming into the carpark and stop the car at a random free space. 3) Simulate car exiting the carpark after random time between 5 to 10 seconds. -
Click send and follow the instructions on the screen. Usually, it asks for permission to execute a shell command or create necessary files.
-
Wait for the process to complete and click "Keep" to store the files.

Test our App
-
Open the html file in your browser and there you go.