Skip to content

Commit

Permalink
Clarify launch.json step & add Nuxt.js debug link
Browse files Browse the repository at this point in the history
* Add a link to help Nuxt.js users debug with VSCode
* Rephrase step 2 of the "Configure launch.json File" section for clarity in case the user already has existing configurations that they want to keep alongside the tutorial's
* Use `js` formatting over `json` for extra readability (the `js` formatting supports JSON objects and has additional color-coding)
  • Loading branch information
calvwng committed Oct 13, 2018
1 parent 037e972 commit 224c34a
Showing 1 changed file with 18 additions and 17 deletions.
35 changes: 18 additions & 17 deletions vuejs-cli/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@ This recipe shows how to use the [Debugger for Chrome](https://github.com/Micros

**Notice**: Please be aware that we have found issues with the sourcemaps generated by vue-cli, which are causing problems for the debugging experience in VS Code. See https://github.com/vuejs/vue-loader/issues/1163

If you're using Vue.js through the Nuxt.js framework, see https://codeburst.io/debugging-nuxt-js-with-visual-studio-code-724920140b8f

## Getting Started

Expand Down Expand Up @@ -65,24 +66,24 @@ Then click on the gear icon to configure a launch.json file, selecting **Chrome*

![config_add](config_add.png)

2. Replace content of the generated launch.json with the following two configurations:
2. Update the generated `launch.json`'s `configurations` to include the "vuejs: chrome" configuration as seen below:

```json
{
"version": "0.2.0",
"configurations": [
{
"type": "chrome",
"request": "launch",
"name": "vuejs: chrome",
"url": "http://localhost:8080",
"webRoot": "${workspaceFolder}/src",
"breakOnLoad": true,
"sourceMapPathOverrides": {
"webpack:///src/*": "${webRoot}/*"
}
}
]
```js
{
"version": "0.2.0",
"configurations": [
{
"type": "chrome",
"request": "launch",
"name": "vuejs: chrome",
"url": "http://localhost:8080",
"webRoot": "${workspaceFolder}/src",
"breakOnLoad": true,
"sourceMapPathOverrides": {
"webpack:///src/*": "${webRoot}/*"
}
}
]
}
```

Expand Down

0 comments on commit 224c34a

Please sign in to comment.