From 9838a77a571d24deeca391b724cdc657057e6cf6 Mon Sep 17 00:00:00 2001 From: "Luke W. Johnston" Date: Tue, 16 Apr 2024 17:52:19 +0200 Subject: [PATCH 1/2] docs: :memo: copied over and slightly edited @signekb's related PR on this topic --- entries/debugging.qmd | 23 +++++++++++++++++++++++ 1 file changed, 23 insertions(+) create mode 100644 entries/debugging.qmd diff --git a/entries/debugging.qmd b/entries/debugging.qmd new file mode 100644 index 00000000..4d999301 --- /dev/null +++ b/entries/debugging.qmd @@ -0,0 +1,23 @@ +--- +title: "Debugging in VS Code" +--- + +In each Seedcase software repository is a file called +`.vscode/launch.json` with a debugger called `"seedcase-debugger"`. This +file gives us the ability to set break points and assess variables and +views at these break points by using the built-in "Run and Debug" +feature in VS Code. + +To use the debugger: + +1. Click the "Run and Debug" icon on the sidebar menu in VS Code +2. Check that it says "seedcase-debugger" in the top, next to the + "Play" icon button (don't click it yet) +3. Set break points where you want the code to stop by going to the + script you want, and click at the left side of the line (a red dot + will appear) +4. Then, in the "Run and debug" tab, click "Play". The debug console + will open. Follow the local host link (as when running + `just start-app`) and go to the page you want to debug. The code + will stop at your break point(s) and you can inspect the variables + at that stage in the tab. \ No newline at end of file From 77fc2db5bd787e19d21555db43afa2d472b8403a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Signe=20Kirk=20Br=C3=B8db=C3=A6k?= <40836345+signekb@users.noreply.github.com> Date: Wed, 17 Apr 2024 09:28:23 +0200 Subject: [PATCH 2/2] Update entries/debugging.qmd --- entries/debugging.qmd | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/entries/debugging.qmd b/entries/debugging.qmd index 4d999301..7afb6517 100644 --- a/entries/debugging.qmd +++ b/entries/debugging.qmd @@ -12,7 +12,7 @@ To use the debugger: 1. Click the "Run and Debug" icon on the sidebar menu in VS Code 2. Check that it says "seedcase-debugger" in the top, next to the - "Play" icon button (don't click it yet) + "Play" icon button (don't click it yet, if you want to add break points) 3. Set break points where you want the code to stop by going to the script you want, and click at the left side of the line (a red dot will appear)