DEV Community

Alex Martinez
Alex Martinez

Posted on • Edited on

How to move your code from the DataWeave Playground to Visual Studio Code

This is intended as a short guide. For detailed instructions + video, please see this article.

Set up Visual Studio Code

  1. Install Visual Studio Code.
  2. Install Java 8 and Maven (3.6.3 or higher).
  3. Install the DataWeave extension for Visual Studio Code.

Export/open the code

  1. From the Playground, click on Export.
  2. Extract the .zip file.
  3. Open this folder from VSCode File > Open Folder.

Configure the layout

  1. Open the input file from src/test/resources/main/Playground/inputs.
  2. Open the main.dwl file from src/main/dw.
  3. From the main file, click Run Preview.
  4. Drag-and-drop the layout as you wish.
  5. From the main file, right-click on the canvas and select DataWeave: Enable AutoPreview for the same functionality as the Playground.

Top comments (0)