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

Breakpoints from VS Code are not working #9

Open
vnobis-univ opened this issue Apr 9, 2023 · 0 comments
Open

Breakpoints from VS Code are not working #9

vnobis-univ opened this issue Apr 9, 2023 · 0 comments

Comments

@vnobis-univ
Copy link

In my case breakpoints setted inside VS Code were not working (pausing) browser running the app (I am using Chrome on Ubuntu OS).

To fix it I have done next:

  1. Updated Pixi to 7.2.4
  2. Modified webpack.config in 2 places:
        ....
        output: {
            path: path.resolve(__dirname, 'dist'),
            filename: 'bundle.js',
            // This line is VERY important for VS Code debugging to attach properly
            // Tamper with it at your own risks
            devtoolModuleFilenameTemplate: '[absolute-resource-path]',
        },
        ....
        devtool: argv.mode === 'development' ? 'source-map' : undefined,
        ....

(these changes were grabbed from https://github.com/GuillaumeDesforges/pixijs-typescript-starter )

My VS Code launch.json looks like this:

{
  "version": "0.2.0",
  "configurations": [
      {
          "type": "chrome",
          "request": "launch",
          "name": "Pixi: Chrome",
          "url": "http://localhost:1234",
          "webRoot": "${workspaceFolder}/dist"
      },
      {
          "type": "node",
          "request": "launch",
          "name": "Pixi: Node",
          "outputCapture": "std",
          "program": "./node_modules/.bin/webpack",
          "args": ["serve", "--mode=development"],
      }
  ],
  "compounds": [
      {
          "name": "Pixi: Full",
          "configurations": ["Pixi: Node", "Pixi: Chrome"]
      }
  ]
}

Hope it can help if you encounter same issue.

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

No branches or pull requests

1 participant