Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

VS Code Debugging #814

Open
eg271 opened this issue May 2, 2021 · 5 comments
Open

VS Code Debugging #814

eg271 opened this issue May 2, 2021 · 5 comments
Labels

Comments

@eg271
Copy link

eg271 commented May 2, 2021

Is it possible to run ember electron using the debugging tools in VSCode? i.e. to set breakpoints, etc.

@bendemboski
Copy link
Member

Are you asking about debugging the renderer process (Ember app) or the main process?

@eg271
Copy link
Author

eg271 commented May 2, 2021

the renderer process

@bendemboski
Copy link
Member

I haven't done it myself (I usually just use the dev tools), but if you run ember electron --- <args go here>, the <args go here> will be forwarded to electron. So I would think that you should be able to follow some standard instructions such as these, except changing it to run ember electron:

              "runtimeExecutable": "${workspaceFolder}/node_modules/.bin/ember",
              "runtimeArgs": [
                  "electron",
                  "---",
                  "--remote-debugging-port=9223"
              ],
              "windows": {
                  "runtimeExecutable": "${workspaceFolder}/node_modules/.bin/ember"
              }

(and I think keeping the rest the same). I'd love to hear if this works for you so we can add it to the documentation, or if you're up for it, would love a PR adding this to the documentation.

@RobbieTheWagner
Copy link
Member

@bendemboski for the Ember app, wouldn't it be the same as any other Ember app?

@bendemboski
Copy link
Member

@bendemboski for the Ember app, wouldn't it be the same as any other Ember app?

I think so, except it has to be launched via ember electron, and it has to tell Electron to launch the Chromium renderer processes with the right setup...the above is my guess for how to do that, but like I said, I haven't done it myself, and don't have a ton of experience with VSCode launchers/debugging. Have you used VSCode to debug Ember apps running under ember-electron?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

3 participants