Skip to content

Visual Studio Code: Run and Debug

Petteri Kautonen edited this page Jul 8, 2024 · 2 revisions

1. Rust needs to be installed, see: Install Rust

2. NodeJs 20+ needs to be installed, see, Download Node.js®

3. Install and/or update NPM and Cargo packages by either

a. Running the following commands

  `npm install`

  `cargo install --path ./src-tauri`

b. Running the script that does the same

  Linux and macOS: `./deb_iu`

  Windows: `.\deb_iu.ps1`

4. Run and debug using [Visual Studio Code]

a) Install the following plugins to Visual Studio Code

b) Open the folder of the application

image

image

c) Debug the Tauri application

image

d) Set a break point to your Tauri function

image

Invoke the greet command from the frontend

image

The break point was hit with the name submitted in the UI:

image