Debugging Your App

Guide

To start debugging your io.Connect Desktop app in Visual Studio Code, execute the following steps:

  1. Start io.Connect Desktop with the --remote-debugging-port command line argument and specify a debugging port:
io-connect-desktop.exe --remote-debugging-port=9222

Using the --remote-debugging-port command line argument instructs io.Connect Desktop to listen on the specified port for a debug connection.

  1. Add a new section to the launch.json file of Visual Studio Code with the following configuration:
{
    "name": "io.Connect: Renderer",
    "type": "chrome",
    "request": "attach",
    "targetSelection": "pick",
    "port": 9222,
    "webRoot": "${workspaceFolder}",
    "timeout": 30000
}

⚠️ Note that the port number in the launch.json configuration must be the same as the one specified in the --remote-debugging-port command line argument for starting the io.Connect Desktop executable file.

  1. Start your app. To debug your app locally, start your app on localhost or other development server and update the "url" property in your app definition with the respective localhost or development server URL.

  2. Select the io.Connect: Renderer profile from "Run and Debug" in Visual Studio Code.

  3. Select your app tab and start debugging.