How can I configure the Chrome Browser without web-security in launch.json
file in VS Code? I installed the VS Code extension Debugger for Chrome and my launch.json seems so:
{
"version": "0.2.0",
"configurations": [
{
"type": "chrome",
"request": "launch",
"name": "Launch Chrome",
"url": "http://localhost:8100/",
"webRoot": "${workspaceRoot}"
}
]
}
This code launch Chrome with web-securities. How can I configure this file so that I can launch Chrome with this parameter: chrome.exe --user-data-dir="C://Chrome dev session" --disable-web-security
Right click on desktop, add new shortcut. Add the target as “[PATH_TO_CHROME]\chrome.exe” --disable-web-security --disable-gpu --user-data-dir=~/chromeTemp. Click OK.
Right-click the Google Chrome desktop icon (or Start Menu link). Select Properties. At the end of the existing information in the Target field, add: " --allow-running-insecure-content" (There is a space before the first dash.) Click OK.
just add
"runtimeArgs": [
"--disable-web-security"
],
So your launch.json will look like:
{
"version": "0.2.0",
"configurations": [
{
"type": "chrome",
"request": "launch",
"name": "Launch Chrome",
"url": "http://localhost:8100/",
"runtimeArgs": [
"--disable-web-security"
],
"webRoot": "${workspaceRoot}"
}
]
}
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With