Until now I've only used VSCode with Illustrator. Now I'd like to debug ExtendScript for Photoshop in VSCode as well. If I simply choose "Photoshop" as the target and debug VSCode automatically tries to run the script in Illustrator. I've read I need to edit the "Launch.json" to make a "compound" section for "multi-target debugging". Does someone know how to do that?
As you can see, it's the "targetSpecifier" property that tells the debugger which app to target. You can find the version of Illustrator by doing app.version, and taking the main version number (140 for me) and adding 0.64 for 64 bit.
Note that you sometimes it might be better to create a new workspace for Photoshop scripting vs Illustrator scripting. It's up to how you work. With large projects you'd make a workspace for each job.