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

Fixed URL for VSCode #129

Merged
merged 1 commit into from
Nov 13, 2023
Merged

Conversation

sushantkadam15
Copy link
Contributor

Summary of the PR

This PR addresses the issue reported on GitHub: GitHub Issue Link. It aims to fix a problem that occurred after a new VS Code update, which prevented opening React components in VS Code from the browser. The solution involves changes to the Index.ts file.

Changes Made

In the Index.ts file, modifications were made to the allTargets object. Specifically, changes were made to the URLs for VS Code and WebStorm. Here is the code snippet with the modifications:

export const allTargets: Targets = {
  vscode: {
    url: "vscode://file${projectPath}${filePath}:${line}:${column}", // Old url vscode://file/${projectPath}${filePath}:${line}:${column}
    label: "VSCode",
  },
  webstorm: {
    url: "webstorm://open?file=${projectPath}${filePath}&line=${line}&column=${column}",
    label: "WebStorm",
  },
};

Copy link

vercel bot commented Nov 8, 2023

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Comments Updated (UTC)
locatorjs ✅ Ready (Inspect) Visit Preview 💬 Add feedback Nov 8, 2023 3:59pm

@joelbqz
Copy link

joelbqz commented Nov 8, 2023

this is a problem with VSCode, not LocatorJS, it breaks many other apps, like React DevTools or Next.js error pages and all of them still use the same link structure

this should be fixed on VSCode end

It seems VSCode did this change intentionally but then this breaks other tools using VSCode url 🙂

@sushantkadam15
Copy link
Contributor Author

sushantkadam15 commented Nov 8, 2023

this is a problem with VSCode, not LocatorJS, it breaks many other apps, like React DevTools or Next.js error pages and all of them still use the same link structure

this should be fixed on VSCode end

It seems VSCode did this change intentionally but then this breaks other tools using VSCode url 🙂

@joelbqz 👉🏻 microsoft/vscode#197450

@infi-pc
Copy link
Owner

infi-pc commented Nov 13, 2023

It looks good, thanks for fixing @sushantkadam15

@HiChen404
Copy link

Cannot open vscode after change on Windows.
vscode: 1.84.2 latest

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

Successfully merging this pull request may close these issues.

4 participants